4/2 Is there an interpreted version of C or C++ that can be used for
educational purposes? It doesn't have to be full-featured or
strictly adhere to the standards, but it's painful for students
to change a variable in a for loop and then wait for a compile
to see how it changes the result. Something really lightweight
would encourage them to play around a lot more and learn more in
the process.
\_ There are interpreted versions of C around. I know of one at UC
Davis, although I don't know the name and have never tried it.
\_ Seriously, for this level of programing why are you using C?
There's all sorts of better learning languages that aren't going
to get bogged down in C land.
\_ Because this is to teach students C/C++ in particular and not
CS/logic. Same reason why not to use perl or python in this
instance. Imagine that you want to teach high school students
C/C++. I don't want to use a 'learning language' like
Pascal, because the objective it to learn the fundamentals
of the C/C++ language. Many already know Java anyway. We
can use a real compiler when the projects get more complex,
but at Ground Zero an interpreted version of C would be nice.
\_ I would argue that the compiling process is a pretty
fundamental aspect of C/C++. So becoming comfortable with
that (teach them to use make at the same time?) is part
of learning the language. For simple programs compiling
should be really simple to do. An IDE is even simpler but
probably harder to see what is really going on (Visual
Studio feels like using MS Office or something instead of
seeing the individual steps.)
\_ We are using Visual Studio, but it is far too
cumbersome to start with. One compile of "Hello
world!" takes a few mins even on modern h/w. It would
be nice to be able to prototype simple programs
or 'play' outside of the compiler. It is a PITA to
recompile every time to do a simple change to see
what might happen and it restricts people from wanting
to experiment.
\_ Few mins for hello world? Something seems wrong.
At any rate a simple editor + gcc would definitely
be easy. Just edit hello.c, gcc hello.c, a.out.
Rinse, repeat. Well, good luck.
\_ Or "cl hello.c" if Visual Studio is in your path
environment variable.
\_ well this then, is your biggest problem. were you using
a linux host, gcc would compile simple C programs in a
fraction of a second.
Barring switching over to Linux, you could potentially
try using gcc under cygwin, also very fast. -ERic
\_ Can't switch to Linux as their lab runs WinXP.
\_ reread my whole comment, including the gem about
cygwin, which runs fine under winXP. -ERic
\_ I read it. I was just explaining why
Linux isn't an option. Thanks.
\_ Why not use perl? If you have to use C, try cint from CERN:
http://root.cern.ch/twiki/bin/view/ROOT/CINT
\_ Please, not perl. Python. Ruby. Hell Scheme. Anything
but perl.
\_ cint looks interesting and I will play around with it.
\- long ago, there was "Saber C" ... i dunno what is the current
state of Sabre C/codecenter. Do these studnets know how to use
gdb? I dont think the "problem" is recompiling, it is syntax
and inspecting data structures. Why dont you use lisp. --psb |