-> It can really streamline your code at times. I love to use it when
-> testing for even or odd numbers, for example:
->
-> IF Number% AND 1 THEN 'odd
->
-> is much nicer than
->
-> IF Number% \ 2 Number% / 2 THEN
True. Mind you,
IF Number% MOD 2 THEN 'odd
is just as neat!
I rather like using "truth values":
True% = Something = Something_else
.... 'whatever you like here
IF True% THEN...
Sometimes I even do arithmetic with the truth values, combining several
of them in mathematical ways.
All this tricky stuff is fun, and undoubtedly time-saving, but it isn't
fundamental to the concepts of BASIC. I am sure there are plenty of
perfectly competent programmers here who are looking at the above bits
of code and wondering what they are all about.
dow
--- PCBoard (R) v15.3 (OS/2) 5
---------------
* Origin: FidoNet: CAP/CANADA Support BBS : 416 287-0234 (1:250/710)
|