1. Re: strings, Re: where is everybody? Re. etc..
On Wed, 01 Nov 2000, Ben Fosberg wrote:
> I'd vote for this suggestion; some of us are literate, but not
> particularly numerate.
> ...
> Come on, Robert - give us mortals a break.
>
I initially signed up for this list because I saw Euphoria as something
I had been looking for; a simple, clean, and easy to use programing
language. Granted, it had some flaws, but it seemed that those problems
were being addressed, and that there was even the possibility of
we users influencing the direction the language would take.
Lately, I have stayed on the list because it has become a source
of some mild amusement, as Rob's idea of a "single, simple flexible
data type" repeatedly bangs its head against the hard wall of reality. (1)
I'm afraid others have found it more painful than amusing, and have gone on
to other things.
Typelessness just won't work, because while it may be true that
"to a computer, everything is a number", in the real world, everything is
most certainly *not* a number. see (2)
Since computers are stupid, we must either tell the
computer *in advance* what sort of data we intend to store, and how it
should be used, (age : integer; name : string;) so the computer
can manipulate and display the data properly using generic methods,
-OR-
we can foist all such work off onto the programmer, who must choose the
correct method to apply each and every time that particular bit of data pops
up.
Euphoria has (mostly) chosen the second method.
The debugger doesn't ask for our opinion, so it just displays
things the only way it knows how - as a number. That wouldn't
be so bad if it were limited to the debugger, but the effects of this
"everything's a number" approach taint the entire language,
making the programmer's job more difficult.
Depending upon what type of data we *think* is currently stored in a
variable, we must choose one of several possible functions which "may"
manipulate the data the way we want - but only if our assumption about
what is stored there is still valid.
Should we write "if name = "Mr. Smith", or "if equal(name, "Mr. Smith"),
or is it "if equal(age,19)...."
Bang! (sound of programmer's head hitting aforesaid wall)
How about "print(age)" , "print(name)"? "puts(name)"
Bang! again.
Let's see, puts() works for sequences, unless it's a nested sequence....
more banging sounds.
So, in effect, instead of declaring a type once at the beginning of a
program, and having a short, clean list of functions to manipulate them,
Euphoria requires us, in effect, to declare anew the type of a variable
with each and every use of that variable thru-out our program, by
choosing from a longer and less obvious list of type specific functions.
Is it any wonder that newcomers have a rough time getting started?
Regards,
Irv
(1), Hey, I think Moe, Larry and Curly are funny, too.
(2) "We went to the zoo, and saw an elephant, a lion, and 23."
"My boss is Mr. Smith, and my girlfriend is 19"