[comp.lang.c] Beginning programming

ccel@chance.uucp (CCEL) (01/18/90)

This may seem terribly mundane, but I need a little help.

I am going to be a teaching assistant for two beginner's classes
in C programming next semester, and I am responsible for assigning
and grading all the programming projects. I've never had a class
in C, I just kind of taught myself over the years, and consider
myself a proficient and well-rounded C progarmmer. Problem is, 
I don't know what kind of assignments I should give the poor
hapless budding CS undergrads. The system they will be using runs
Unix, but I think any nice juicy system calls or OS based stuff
would be over their heads.

If anyone has any syllabi (syllabuses?) for a C class they could
send me, or any "basic concepts" that I should be certain to include
it would be very helpful. No need to spawn (fork?) a discussion 
about the basic philosophy of C, but a set of guidelines or 
suggestions would help immensely.  Please use e-mail, I'm sure
everyone else in the world doesn't want to see such mundane
prattle in this newsgroup.

Thanks in advance.

Randy Tidd
rtidd@mwunix.mitre.org
#define DISCLAIM TRUE

josephc@tybalt.caltech.edu (Joseph Chiu) (01/19/90)

ccel@chance.uucp (CCEL) writes:
>I don't know what kind of assignments I should give the poor
>hapless budding CS undergrads. The system they will be using runs
>Unix, but I think any nice juicy system calls or OS based stuff
>would be over their heads.

I'm curious on how others feel about teaching language classes.  In my high
school, they taught standard Pascal, no OS or machine specific calls whatsoever,
and programming was very "vanilla".  Also, we weren't allowed to use certain
"run-time" (or equivalence of a run-time library, anyways) stuff, but instead
had to make most functions from scratch (obvious exception was writeln, for
example...)

Does teaching "pure" language help people learn better?  Or do you feel that
by allowing beginners to immediately plunge into system/implementation   
specifics and allowing them more "Bang for the buck" programming using vendor
supplied non-standard functions would be better?

>If anyone has any syllabi (syllabuses?) for a C class they could
>send me, or any "basic concepts" that I should be certain to include

I don't know about you, but over here, the first CS class was to design a 
mini graphics editor under X-windows (through macros and functions that
took care of most of the setup & parameter passing).  It went through the
whole white book (it even used the ? : operator!) with graphics programming
thrown in...  Perhaps it may or may not be reasonable, depending on the
nature of the students in the class.


Joseph

cjoslyn@bingvaxu.cc.binghamton.edu (Cliff Joslyn) (01/19/90)

I'm in a similar situation as a new C teacher.  I'll email privately,
but I think this group may be interested in strategies on learning and
teaching C.  There are many experts here who have a lot of experience to
share.

Following suggestions from this list, we're using Kochan's /Programming
in ANSI C/ as a text combined w/K+R v.  2.  I found a C tutorial on
Simtel good as a guide on what to cover in what order, and the /C Puzzle
Book/ and Koenig's /C Traps and Pitfalls/ as good sources of quiz and
test problems.  I'm making my own programming assignments.

-- 
O------------------------------------------------------------------------->
| Cliff Joslyn, Cybernetician at Large, cjoslyn@bingvaxu.cc.binghamton.edu
| Systems Science, SUNY Binghamton, Binghamton NY 13901, USA
V All the world is biscuit shaped. . .

drs@bnlux0.bnl.gov (David R. Stampf) (01/19/90)

In article <2810@bingvaxu.cc.binghamton.edu> cjoslyn@bingvaxu.cc.binghamton.edu.cc.binghamton.edu (Cliff Joslyn) writes:
>
>Following suggestions from this list, we're using Kochan's /Programming
>in ANSI C/ as a text combined w/K+R v.  2.  I found a C tutorial on
>Simtel good as a guide on what to cover in what order, and the /C Puzzle
>Book/ and Koenig's /C Traps and Pitfalls/ as good sources of quiz and
>test problems.  I'm making my own programming assignments.
>

	I took a C course many years ago that used the C Puzzle Book almost
exclusively and it was the worst course that I have ever taken - please
reconsider.  The book is full of pathological programming problems and
mistakes and has nothing to do with learning to program.

	You may also want to find out the version of the compiler that the
students will be using.  Where I taught C, there wasn't an ANSI compiler, so
I used K&R v1. instead.  C is confusing enought for the beginning student
without having to explain that not everything in the book is true.

	< dave

Kevin_P_McCarty@cup.portal.com (01/21/90)

In <2810@bingvaxu.cc.binghamton.edu>, Cliff Joslyn writes:
> Following suggestions from this list, we're using Kochan's /Programming
> in ANSI C/ as a text combined w/K+R v.  2.  I found a C tutorial on
> Simtel good as a guide on what to cover in what order, and the /C Puzzle
> Book/ and Koenig's /C Traps and Pitfalls/ as good sources of quiz and
> test problems.  I'm making my own programming assignments.
>

It may be too late for your class, but I notice that Plum Hall has
recently updated and republished the following classics:

Thomas Plum, "Learning to Program in C" (*)
Thomas Plum, "C Programming Guidelines" (*)
Thomas Plum, "Reliable Data Structures in C"
Thomas Plum and Jim Brodie, "Efficient C"

(*) (updated for ANSI C)

"Learning to Program in C" is the one I learned from (back then it was
one of the only ones), and I haven't seen a text yet that comes close
to matching it.  As far as I can tell, Thomas Plum's book is the only
one which lives up to its title:  Learning to _Program_ in C.  Most
other texts I have seen should be titled "Discovering Loaded Weapons
in C" and spend too little time on how to keep your feet clear of the
line of fire.

"Learning to Program" and "Reliable Data Structures" both contain
advice and insights which are highly valuable and, curiously, aren't
easily found elsewhere.  For example, "Learning" is copiously
annotated with warnings about machine dependencies, os dependencies
and compiler dependencies, and how to program to be independent of
them.  I am glad to see these books updated and available again.

Kevin McCarty