Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: c,c++5,c#.

Author: Anthony Cozzie

Date: 09:47:43 08/11/04

Go up one level in this thread


>"It is practically impossible to teach good programming to students that have
>had a prior exposure to BASIC: as potential programmers they are mentally
>mutilated beyond hope of regeneration."
>
>and
>
>"Teaching BASIC should be a criminal offense."
>

The teaching of introductory computer science has always been of interest to me.
 Right now, most people are taught Java first and C second (=an intermediate
language), if at all.  At CMU, I learned C (before I went there), then C++, then
ML, then assembly, and I never really used Java at all, although now the
introductory course is in Java.

What I have always been curious about is how the conventional curriculum would
fare against a bottom-up approach: Learn assembly first, then C, then C++/Java,
and finally a functional language like Haskell or ML.  I think that there is a
lot of handwaving that goes on with programming languages that wouldn't be
necessary if students were taught assembly first (why you can pass an array as a
pointer, why scanf needs an & before int arguments but not strings, why printf
takes variable arguments but no other functions, function pointers, etc).

I would budget the class something like:

6 weeks x86 assembly
  1 week  basic instructions (mov, add, etc), nasm
  2 weeks memory operands AKA pointers & pointer arithmetic
  1 week  branches
  1 week  calling conventions
  1 week  practice
5 weeks C
  1 week syntax, types, & printf/scanf
  1 week loops and conditionals
  1 week arrays & pointers
  1 week strings & string libraries
  1 week structures
3 weeks C++
  1 week classes
  1 week inheritance
  1 week polymorphism

which I believe would fit a 1 semester class, if I did my math right.  Assembly
is so simple that it practically teaches itself, C is incredibly simple when you
know assembly, and C++ is C with a few decorations. This might be a little
aggressive, but I think it's doable.

Combining it into a larger curriculum would give

Semester 1: basic programming (see above)
Semester 2: algorithms and datastructures (basic sorting, trees, hashes, etc)
Semester 3: functional programming (haskell or ML)
Semester 3: low level programming (virtual memory, threads, fork(), etc)
Semester 4: advanced algorithms (runtime analysis)
Semester 4: parallel programming + basic computer architecture (pipelines,
caches, remote memory)

After which the student would be prepared for most upper level computer science
classes.

anthony



This page took 0.01 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.