|
From: | Ernie Braganza |
Subject: | Re: A new Scheme tutorial (Jean Abou Samra) |
Date: | Sun, 24 Jul 2022 11:19:32 -0400 |
> Ouch! I see what you mean. And this is meant to be simplified? But the
> problem really is that if a user tries to use an identifier with an
> illegal syntax, how do they know? This is rather like those really
> annoying websites which ask you to choose a password, and then tell
> you that it's illegal without telling you why.
>
Simple: don't use too weird identifiers :-)
I'll try to rephrase that part again. The point of mentioning this is
to explain that '+', '-', '*', '/' are just procedures, not special
syntax, and to address the question that I imagine this immediately raises
in the mind of a reader used to more mainstream programming languages:
"what, a procedure called '+', is that really valid"? There are also
two conventions that are useful to know:
- question mark at the end of a predicate (explained later in
the tutorial),
- exclamation mark at the end of a side-effecting procedure
(I'm not showing any of these in this basic tutorial, so
I didn't explain it).
It's not really encouraged to get creative about special characters in
your variable names. Just stick with the conventions.
Cheers,
Jean
[Prev in Thread] | Current Thread | [Next in Thread] |