Re: Programming languages for the very young
From: Michael D. Ober (obermd-._at_.-alum-mit-edu-nospam)
Date: 01/28/04
- Previous message: John Doty: "Re: Programming languages for the very young"
- In reply to: Ray Dillinger: "Re: Programming languages for the very young"
- Next in thread: Joe Marshall: "Re: Programming languages for the very young"
- Reply: Joe Marshall: "Re: Programming languages for the very young"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Wed, 28 Jan 2004 15:56:54 -0700
"Ray Dillinger" <bear@sonic.net> wrote in message
news:4018234F.E0A1ACEB@sonic.net...
> abstraction.
>
> Before you tell me that assembly has subroutine calls, note that I am
> talking about machine code here; I know that there are assemblers which
> package up subroutine patterns as macros, but I'm not talking about a
> macro assembler language, I'm talking about machine code, or equivalently
> a non-macro assembler.
>
The last time I looked, all processors except the IBM mainframe processors
have machine level SUB and RET instructions. These are the two instructions
required for subroutines. Yes, some assemblers allow you to put the
registers on the SUB call line and the assembler packages the sub for you,
but the underlying stack and register manipulations are done via a hardware
level instruction pair - one to create a new stack frame and one to unroll
it.
As for VB 6, it has a lot of high level memory management features that C
and C++ can't touch. You never have to deal with a pointer except when
referencing Windows API functions that call for a pointer to a buffer. You
also don't have to deal with memory leaks and uninitialized memory on the
heap. You can event force the compiler to require variable declarations
(but not types, unfortunately).
You can write garbage in any language - you can also write maintainable code
in any language. You just have to understand the structure of and how to
implement program design so that the program is maintainable.
Is VB the best language to teach programming, probably not. But neither are
C or C++. VB forces some quirky structures simply because it's not truly
object oriented and it allows global variables (I consider them to be the
data storage equivalent of "GOTO"); C++ because you have to spend a lot of
time thinking about memory management (which is ok if that's what you're
trying to learn). From a standpoint of learning how to structure software
for correctness and maintainability, I'd pick CLU as it only readily allows
one major bad habit - putting your control structures too low in the code.
Mike Ober.
CLU, Scheme, FORTH, Intel Assembler, VAX Assembler, IBM BAL (Assembler), C,
C++, VB, Clipper 5.x, Motorola 68xxx Assembler, Pascal
- Previous message: John Doty: "Re: Programming languages for the very young"
- In reply to: Ray Dillinger: "Re: Programming languages for the very young"
- Next in thread: Joe Marshall: "Re: Programming languages for the very young"
- Reply: Joe Marshall: "Re: Programming languages for the very young"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|