• Please review our updated Terms and Rules here

When does BASIC not become BASIC?

CP/M User

Veteran Member
Joined
May 2, 2003
Messages
2,986
Location
Back of Burke (Guday!), Australia
I'm curious what peoples thoughts are regarding this language, which through the decades has been through many alterations and even through alterations, the language is continued to be called BASIC, even when it's been influenced by other languages. Though when I look at a flow chart of all the languages made, I notice BASIC was influenced by Fortran IV and another early language called JOSS which was influenced by Algol 58 and before that Fortran I, so I wonder if one of those earlier languages had something like Procedures, is where BASIC could inherit Procedures even though it wasn't part of the early Dartmouth BASIC?

I was also wondering if variable declaration and naming were important, so normally in BASIC varables don't need to be given a type, although I'm unsure how later BASIC (Visual BASIC for example) would handle that, so 'a=1' and a equals 1, and the names themselves in BASIC can be a mixture of letter followed by number, though wondered if any BASIC ever went away from that and used a letter to represent a variable type followed by a number to represent it's place?
 
10 years ago, I would have said "when it was compiled." But since then, I've read about the history of BASIC and the variations in the different PCs.

So I've had to change to "when it did away with line numbers."
 
Does Fortran 2003 look much like FORTRAN IV?

Languages evolve. Wrote a commercial BASIC myself--extended it so it was useful.

Chuck,

What were the values/features that you needed compared to what was available at the time?

Tom
 
10 years ago, I would have said "when it was compiled." But since then, I've read about the history of BASIC and the variations in the different PCs.

So I've had to change to "when it did away with line numbers."

That would place it somewhere between GWBASIC and QuickBASIC/QBASIC, though QuickBASIC and QBASIC supported Line Numbers, they weren't deemed necessary, that's unless there's something else I'm not aware of which didn't support Line Numbers.

Does Fortran 2003 look much like FORTRAN IV?

Languages evolve. Wrote a commercial BASIC myself--extended it so it was useful.

It seems to be more about portability these days with Fortran, to the point of making C Coding interchanagable, which seemed to start with Fortran 2003.
I don't fully understand the application of the language and it's role these days compared to back in 1957, so for all I know, it's being used in Lab environment to analyse COVID bacteria or if it's used to power the Great Hadron-Collider, perhaps both. I've never seen a book called '50 Fortran Games to try' though.

Back to the BASIC dilemma though, by definition it's Beginner's All-purpose Symbolic Instruction Code and as such is tailored for the Beginner, though not all agree it should be a programmers 1st language. In it's day though it was perhaps more readable than Algol, Fortran and if coding errors were quickly reported in BASIC, perhaps it was friendlier than other languages at the time, that's not suggesting the other languages had no Error Handling, though when one comes to 'All-purpose', it's more apparent it's a Language for a wide range of applications.
 
I don't fully understand the application of the language and it's role these days compared to back in 1957, so for all I know, it's being used in Lab environment to analyse COVID bacteria or if it's used to power the Great Hadron-Collider, perhaps both. I've never seen a book called '50 Fortran Games to try' though.
Well, the thing is that there actually were games written in FORTRAN (ADVENT being the canonical example,) simply because that was the lingua franca for general-purpose computer programming before BASIC took off enough to become comparably omnipresent. It's just that those big-book-o'-games collections didn't start getting published until the microcomputer market exploded, by which point BASIC was already the de facto standard.

Anyway, my answer to the question is "when it's Java in drag."
 
That would place it somewhere between GWBASIC and QuickBASIC/QBASIC, though QuickBASIC and QBASIC supported Line Numbers, they weren't deemed necessary, that's unless there's something else I'm not aware of which didn't support Line Numbers.

Gordon Eubanks 1976 manual for BASIC-E has line numbers being optional except for targets for GOSUB and GOTO. Structured BASIC out of Dartmouth removed all the need for line numbers. That was also in 1976.
 
Anyway, my answer to the question is "when it's Java in drag."

Actually C# in drag, but that's a quibble.

And I would agree with that statement.

Visual Basic up to .NET was, indeed, BASIC. But VB.NET is C# with some BASIC style syntax sugar.

BASIC is under-appreciated because of its bad reputation, not necessarily undeserved. But its impact on empowering people to make use of computers is undeniable. It did far more to make the computer more accessible back in the day.
 
Gordon Eubanks 1976 manual for BASIC-E has line numbers being optional except for targets for GOSUB and GOTO. Structured BASIC out of Dartmouth removed all the need for line numbers. That was also in 1976.

I'd imagine in that case they took that structure from how FORTRAN did it, with every line being allowed an optional line number. Meaning that they wouldn't need to be sequential or related to the position in the file.

I don't feel that line numbers really are a key feature of BASIC, more so that had prominence in implementations on home microcomputers because they allowed for the implementation of a very simple line editor that didn't have any confusing modes for the end user. If you took something like Microsoft BASIC for CP/M and replaced the line numbers with labels, would that really be a huge change in the language? I'd argue not.
 
Chuck,

What were the values/features that you needed compared to what was available at the time?

Tom

I'd have to make a list, but one notable one was management of data structures; static allocation was another. Dynamic allocation of string storage is great until you run out of memory when executing a mission-critical task. The I/O was considerably different (e.g. ISAM was a standard access method) as was string handling. Multi-user was another aspect. We did manage to avoid explicit data typing, so that there are character strings and numbers. Labels, if used could be numeric or alphanumeric. And it was compiled; there was no interactive mode.

In other words, more like a production language than a language to teach programming.
 
Well, the thing is that there actually were games written in FORTRAN (ADVENT being the canonical example,) simply because that was the lingua franca for general-purpose computer programming before BASIC took off enough to become comparably omnipresent. It's just that those big-book-o'-games collections didn't start getting published until the microcomputer market exploded, by which point BASIC was already the de facto standard.

Anyway, my answer to the question is "when it's Java in drag."

Was so silly of me not to type in "Fortran Games" and you're right, by the time '# BASIC Games for you' type books came out BASIC would of been in Full Swing. Most of the Fortran Books I used to see and the one I have focus on Fortran-77 for more serious applications.

Gordon Eubanks 1976 manual for BASIC-E has line numbers being optional except for targets for GOSUB and GOTO. Structured BASIC out of Dartmouth removed all the need for line numbers. That was also in 1976.

I should have realized this, since I once wrote a little Star Field demo in CBASIC86 and had to incorporate a small timing routine in Assembly so every IBM-Compatable returned the same timings. :eek:
 
I went through the 1964 Manual for Dartmouth BASIC and prepared a list of the Commands, Functions, etc found there if anyone's interested:

BASIC Commands:

Code:
* DATA
* DEF FN
* DIM
* END
* FOR
* GOSUB
* GOTO or GO TO
* IF .. THEN <Line Number>
* LET
* MAT(?)
* NEXT
* PAGE
* PRINT
* READ
* REM
* RETURN
* STOP

(?) I don't know anything about MAT and was unsure if it's meant to be a Command for within an Listing or an Command used during the Editor for the aid of Debugging, a number of commands follow on after MAT including PRINT, LET, etc.

Command Line Commands:

Code:
* RUN
* LIST
* SCRATCH (Deletes current problem, retains the filename)


Filename Based Commands:

Code:
* CATALOG (display a directory)
* NEW (deletes current problem and asks for a new Filename)
* OLD (Retrieves a previously saved problem)
* RENAME
* SAVE
* UNSAVE (deletes previously saved problem)

Math Functions (this is where a number of functions from JOSS are used):

Code:
* ABS
* ATN
* COS
* EXP
* LOG
* SIN
* SQR
* TAN

Other Functions:

Code:
* INT
* RND

Special Characters:

Code:
+ - * / ^ =
( ) < > . , ;

Loops:

Code:
*IF <condition> THEN <line number>
* FOR <condition> with the option of STEP
* NEXT <condition>
GOTO or GO TO exists, though used with IF..THEN <line number> to prevent an Infinite Loop

One interesting fact in their Manual is 'Arrays' aren't referred to as Arrays, but as 'Lists and Tables', the language doesn't go beyond a Table (the equivalent of a 2D Array), though by Default a List of 10 items is allow, any more DIM needs to be used with the Specified length. I mention this because I had a discussion with someone on another forum regarding the Differences between 'Arrays' and 'Lists and Tables' and specifying each had their own Advantages and Disadvantages, though I think it was a modern day comparision with how a language like Python uses 'Lists and Tables'.
 
MAT is a matrix operator. Matrix assignment, input, output, etc. BASIC PLUS had these, the MS BASICs didn't bring them forward.

A List is a higher level concept, an Array is an implementation of a List (in contrast to, say, a Linked List). The MS BASICs also default to 10 elements in an undefined array.
 
Languages evolving makes sense if you're referring to changes made by committees. When a single corporate entity makes huge changes to a language's sytax, to the point it's bares little resemblance to what was more or less standard (not necessarily a standard), that's something else. M$ BASIC/A, compiled BASIC, Quck Basic, Qbasic are all legitimate versions of the language in my opinion. Visual Basic is something else. It's not even called BASIC. It's Visual Basic.
 
MAT is a matrix operator. Matrix assignment, input, output, etc. BASIC PLUS had these, the MS BASICs didn't bring them forward.

That's really cool if it's a Mathamathical series of calculations to return a series of results, though I guess later on for 8-bit Microcomputers it was too tasking on computers with limited memory?
 
Thanks CP/M User, I appreciate you preparing the list of keywords and functions.
One of the early books I acquired on BASIC was IIRC 'BASIC for Everyone' (not the Tandy book) which was using Dartmouth BASIC.
I got it cheap at a book sale and I wonder now if that was because of describing things like MAT and how to log on on a campus teletype that it wouldn't have really appealed to a microcomputer user.
I was very envious of the MAT commands for matrix manipulation as I wanted to do some simple 3D graphics at the time, and those built-in commands would have made things like matrix multiply look a lot prettier than subroutines with nested loops.
In the end I just used the example BASIC code from an article on 3D graphics in an issue of Australian Personal Computer magazine (I think Dick Smith was on the cover) to draw a cube.

One reason I think BASIC became so popular was that, when other computing centres frowned upon students writing and playing games as a frivolous use of computing resources, Professor Kemeny actively encouraged it.
There is a comment referring to this at 29:59 in the very interesting 'Birth of BASIC' documentary on YouTube:
https://youtu.be/WYPNjSoDrqw?t=1799
 
Visual Basic version 1 through 6 follow the same pattern as earlier MS BASICs. VB has an extended event trigger mechanism behind a screen builder but fundamentally it is no different from using ON KEY or any of the other event handlers in MS BASIC. Changing to a cooperatively multi-tasking GUI requires some changes to programming practices but the language is still the language.

True BASIC tried to introduce the joys of all the advanced Dartmouth BASIC functions to the micro market but apparently more were interested in easy sound and graphics with MS than in having matrix functions. I think Microsoft's major advantage was having a BASIC that fit in 8k right when 8 KB ROMs were cheap.
 
Thanks for the interesting feedback 1944GPW. The book I found called 'BASIC for Everyone' is by Thomas Worth from 1976, I only saw snippets of it through Archive.org and Google Books, though that appears to be the one I guess.
Think I was wrong regarding the MAT command. I'm looking at the 1 Oct 1964 edition of BASIC and MAT is a part of Part IV dealing in Card BASIC. So it appears that a DATA deck needs to be setup as part of the Program Deck, though it needs to be setup after the END and it needs to have no line numbers or DATA statement, though is still an interesting concept and was watching some interesting video earlier showing how Matrix Operation worked to instantally. This was what I came up with just to see how it would look when MAT isn't available:

Code:
100 READ a(1),a(2),a(3)
110 READ b(1),b(2),b(3)
120 FOR p=1 TO 3
130   a(p)=a(p)+b(p)
140   PRINT a(p);
150 NEXT p
160 PRINT
170 c=c+1
175 IF c<>10 THEN 140
180 END
190 DATA 10,20,30
200 DATA 1,2,3

I guess if MAT were used, it could be:

MAT READ a(3),b(3)
MAT LET a(3)=a(3)+b(3)

and like the earlier example, the resulted sequence would be: 11 22 33


Re: Standards, I wasn't trying to start a fight by opening up a Manual about Dartmouth BASIC from Oct 1 1964, but it has some interesting traits, for example what became popular in later Microcomputer BASICs is the use of the Colon Symbol ':', to have seperate commands on the same line, which wasn't a feature of that BASIC (unless someone knows otherwise) and there's no INPUT command to input characters within a program, this early version was definitely in that phase of coding computer problems and return the correct results, such a problem still existed when this Manual was released. I do have a later Manual (also online) from 1968, which adds more function to the language, which I was going to add in a week or so if it's not going to cause drama.
 
Yep that's the book! It was a large quarto size paperback with a blue cover and a green circle on the front. I regret tossing it out some 15 years or so ago, but nice to know archive.org has it. Your example could then MAT PRINT a to dump it out.

I reckon krebizfan hit the nail on the head about dropping (boring old) MAT for point and line graphics and simple sound capabilities. Kemeny was a mathematician and MAT would definitely have fitted into his vision of the language as he saw it; in the video I alluded to above there is some footage of him asking his mathematics class to solve some problem in BASIC.
 
Back
Top