Twitter’s Trammell Hudson highlights an article from 1977 where it was suggested adopting Python-like syntax in BASIC.
Russ Walter suggested changes in January/February 1977 issue of Personal Computing Magazine. At that time 90% of business code was in COBOL but 60% of that done by students was in BASIC (when they weren’t doing their FORTRAN homework).
John Kemeny and Thomas Kurtz invented BASIC at Dartmouth College, in 1963, by simplifying the computer language ALGOL. They retained the ALGOL words FOR, TO, STEP and THEN but eliminated ALGOL’s complex options such as integers versus reals (BASIC automatically gives you reals), local versus global variables (BASIC automatically gives you globals), and simple versus compound statements (BASIC forces you to use simple statements).
BASIC became popular for several reasons. It was easy to learn. It used an exciting interactive timesharing system. It compiled quickly. It included four simple pairs of jobcontrol commands: HELLO & BYE, NEW & OLD, SAVE & UNSAVE and LIST & RUN. For editing, it used statement numbers: “to delete a line, just type the line’s number; to correct a line, just retype it.” Kemeny and Kurtz mastered politics: motivating their students to write the compiler and ran an in-service program for high school teachers, who spread the good news. But the big clincher came when Digital Equipment Corp. decided to put BASIC on its PDP-8 computers as an alternative to FOCAL. PDP-8 users preferred BASIC to FOCAL so much that Digital chose BASIC to be the main language for its PDP-11.
But BASIC suffered as it’s creators never wanted to sacrifice backwards compatibility. Mistakes could never be unmade.
Walter argues in the article about several issues that could easily be corrected by adopting elements chosen by Python:
- Using a colon for range values
- Indenting FOR/NEXT loops and subroutines
- Indenting IF statements
- Long variable names (most BASIC implementations only allowed single character variable names in the older days)
- Switch comma and semicolon in PRINT statements
- Better commenting methods
- Eliminate unneeded statement types
Again, this was in 1977! Python had yet to be invented by Guido van Rosssum until 1990. Perhaps it was language influencers in preceding years that mulled over best practices which lead to the development of our more modern languages like C and then Python?
And to those who say that BASIC did evolve, that is true also. Differing groups implementing BASIC on microcomputers build on the work of early BASIC. While indentation wasn’t a huge thing at first, longer variable names and comments were introduced. By the time Microsoft introduced Visual BASIC, most modern improvements had been made.
The original 1977 article suggesting changes is a very interesting read in language evolution.
What are your recollections of BASIC and it’s evolution? Let us know in the comments below.
I did learn BASIC about the same time this article was written, although I wouldn’t have read it. My father might have. I used BASIC almost exclusively for 20 years, even though I also learned FORTRAN and PASCAL. My first professional programming jobs were also in BASIC, so it will always have a special place in my heart. Looking at the changes that were proposed in this article, I can see some of what was adopted by Python in it (not so much PASCAL or C). As someone who uses Python almost exclusively these days, I can see some of what was proposed by Mr. Walter back then in it. I can do the quick & dirty things with it that I could do with BASIC back then. I basically use it as a hobby these days.
I learned BASIC on a TRS-80 and could totally agree that a colon instead of the word ‘ TO ‘ would have been the way to go. I never used LET or END in any of the programs I wrote because it was just extra typing unless I needed the the program to END immediately. When I took programming in High School the BASIC that was taught was Chipmunk BASIC which is still avaliable for the raspberry pi. It did have Subroutines and Returns statements; I always felt that the FOR/NEXT Combination helped me understand the RETURN statements usage. Beside you could do some interesting things with NEXT statements.