Re: Last Ninja Programming Language



Nice to see that I ignited some passion on the subject.

Anders Carlsson said:
"Like a game that requires Simons' Basic to execute?"

I think you picked the perfect example of which BASIC extention not to
use. Although the extensions in Simon's are certainly useful, the
cartridge implimentation blows. I was, of course, thinking of one that
actually loaded into memory. But truthfully if you're only writing the
program for yourself or a limited audience there is no reason you
couldn't use Simon's Basic.

White Spirit said:
"You'll then have to write your own routines to deal with memory
locations limited to +255 or between ->128 and 127 for signed integers,
along with routines to deal with arithmetic. Presumably, you would
require integers outside that range, along with floating point
arithmetic. (Strings and characters would >be a lot simpler to
implement.) Consequently, the code would run a lot slower for the
dubious benefit of having local variables."

You're right, it really depends on how complex a local variable
implimentation you want to make. You could go full out and impliment a
complete complimentary variable structure that mimics the regular BASIC
variable structure. It might even be fun to write. Or if your needs
are simpler (such as local strings) you could just store the characters
in a buffer. That's a pretty wide range of what could be done. But,
the point is it can be done.

White Spirit said:
"Linked lists. Trees. Structs. Objects"

It really depends on whats inside these data types as to how well BASIC
can handle them. Complex structures would need careful evaluation on
what sort of routines would be best for handling them. And that should
be the deciding factor for how to impliment them.

White Spirit said:
"It's good for simple tasks, and as a beginner's language, but as an
enterprise level development tool... Heheheh."
"For Commodore machines, for any serious purpose, I would use assembly
language. Anything else available is either not a serious language or,
in the case of C, to provide useful code on Commodore machines, it
isn't quite C any more."

What does "enterprise level" and Commodore 64 have in common? In the
end a higher level lanugage, no matter which you choose, is going to
introduce its own set of compromises. And based on the last of your
comment about C I think we might just be in agreement.

Blackjack said:
"``GOSUB MoveEnemy`` is much clearer than ``GOSUB 2770``"

I think you're mostly complaining about having to do it in an out-dated
way. Wouldn't the following be just as clear?:

GOSUB 2770:REM MoveEnemy

When I used to write in BASIC I would write lots of notes. Every
project I worked on would have at least one three ring binder full.
The notes would list what the variables are, a list of major routines,
maybe even the theory of operation or flow of a particular part of the
program. And REM was my friend. I knew the compiler would take the
REM out, but while it was there I would write all kinds of notes to
myself, including what page of the documention to look at to understand
what this part of the code was doing. Still, I've seen more than my
fair share of C programs where there is more comment than there is
code. Likewise I've seen a few where they are so obfuscated that I
don't understand why it runs, let alone what it does. You can commit
the readability sin in almost any language.

Anders, I really liked the Ferdinand program.

20 BULLS=BULLS-1:BUMBLEBEES=BUMBLEBEES+1

would work with the simple change of:

20 BULLS=BULLS-1:BEES=BEES+1

As to this one:

30 IF THISBULL<FAINT THEN .

That's a great example. You're right, parsing problems within BASIC
will be limiting. It will also cut down substantially on the number of
unique variables available as all of the word style variables would be
considered two character varaibles. In the above addition and
subtraction example it would be BU and BE to the computer. I think I
might change the above IF/THEN to soemthing like this:

25 rem T=THISBULL F=FAINT
30 IF T<F THEN .

The REM will be removed by the compiler, so you're only burning code
space. And it still retains about 75% of the readability and it will
run correclty. Add liberally whereever needed.

I think it depends on how much the limits bother you. There are
problems with using BASIC. And, while many of my comments have been
flippant, I'm not advocating for you not to use C. Use what you're
most comfortable with. I just don't quite accept your reasons for not
using BASIC since C will have its own set of issues.

David

.



Relevant Pages

  • Re: Question about jumps
    ... Except you've missed the point that writing numeric I/O routines isn't ... in the book "The C programming language" where they solve ... Markus doesn't know *what* he wants to learn. ... You seem to assume that everyone is saying "printf will work for you ...
    (alt.lang.asm)
  • Re: static class inheritance, generalized
    ... name search scope. ... As the language and framework are OO, the routines have to ... specify in which class they're in. ... header/namespace with solely routines and no classes, ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: PianoKey Program Variations
    ... you can program in just about any language and achieve the ... And you will of course need tok64 to use this: ... rem batchfile to create c64 BASIC program from tok64 input ... 330 poke cr,8: poke cr,0: rem fix off ...
    (comp.sys.cbm)
  • Re: Moving from VBA to Intranet programming
    ... or get one of the into .net courses on ... c# is a language that is just fine for developing web apps. ... asp.net is another language that is an extension of asp using the .net ... > maintaining these programs as "web based" routines. ...
    (microsoft.public.office.developer.vba)
  • Re: OCP and Java
    ... > This can lead to code bloat, by either adding extra routines to ... routines "violate" the OCP, but can be written in any language. ... >> simply declare all methods as virtual. ...
    (comp.object)

Loading