Skip to main content
ReferenceComputing historyBeginner

BASIC: opening programming to non-specialists

From Dartmouth to home computers: how BASIC made programming easier to learn through time-sharing, simple examples and a growing family of dialects.

Show contents

Write a few lines, run them, read the result and try again: at a personal computer, this seems entirely ordinary. In the early 1960s, however, it required two separate problems to be solved. People needed a language they could learn without becoming specialists, and access to a machine that let them experiment without a long wait between attempts.

BASIC, short for Beginner’s All-purpose Symbolic Instruction Code, grew out of this twofold ambition at Dartmouth in 1964. Its story begins at a university, before microcomputers and before Microsoft. It brings together an approach to teaching, a system shared by multiple users and, later, a remarkably varied family of languages.

Before BASIC: a language was only part of the problem

At a computing centre using batch processing, users prepared a program, often on punched cards, and submitted it to a service that processed it with other queued jobs. Results came back after the job had been processed. A typing mistake could mean submitting the work again: the time between an idea and testing it was much longer than the calculation itself.

There were sound economic reasons for this arrangement. A central computer, its peripherals and its operation were costly resources serving many competing needs. Keeping the machine busy made sense. Making efficient use of it did not, however, automatically make learning easier.

High-level languages had already changed programming. FORTRAN, developed by John Backus’s team, made scientific calculations easier to express efficiently. ALGOL provided a notation for describing and structuring algorithms. BASIC would address a different need in learning and access to the machine.

At Dartmouth, the question concerned a wider audience: how could students of the humanities and social sciences learn to program too? A course built around numerical methods, job preparation and the computing centre’s procedures could discourage them before their first useful experiment. Lectures about computers were no substitute for trying to write a program.

Dartmouth: a joint effort by faculty and students

At Dartmouth College in Hanover, New Hampshire, mathematicians John G. Kemeny and Thomas E. Kurtz wanted computing to be accessible beyond the sciences. Earlier experiments with simplified languages helped prepare them for the project. They combined a new notation with an environment designed for beginners.

Kemeny and Kurtz designed BASIC and championed its educational purpose. In Kurtz’s retrospective account, Kemeny wrote a prototype compiler in 1963, while students John McGeachie and Michael “Mike” Busch took the main responsibility for developing the operating system. The language, its compiler and the service that made it usable were distinct contributions to a collective undertaking.

The original hardware paired a GE-225 with a Datanet-30, which handled communications with the terminals. Dartmouth’s institutional timeline dates the first success of the Dartmouth Time-Sharing System, or DTSS, to 1 May 1964, at about 4 am: two identical programs submitted from two teletypes returned correct results. This demonstrated the language working with its environment. The service expanded afterwards: by June, eleven teletypes had access, and a GE-235 replaced the GE-225.

Participants’ recollections do not agree on every detail of that night. Dartmouth Library’s exhibition notes that neither professor remembered being present. The date is firmly commemorated; reconstructing their exact actions or words would be much less certain.

Time-sharing: shortening the learning loop

A terminal sends characters to a central computer and receives its responses. The teletypes used at Dartmouth had keyboards and printed on paper. Picturing a screen at every terminal would be anachronistic.

Time-sharing lets several people use a common installation during the same period. The system switches rapidly between jobs and manages their input and output. While one person thinks or types, another job can receive processing time. Users experience something like individual access without each needing a complete computer.

In batch processing, a program goes through a job queue before its author receives the result. With time-sharing, several terminals communicate with a central system that switches between jobs; each user can revise and rerun a program.

A comparison of principles, not a timing diagram. Time-sharing does not guarantee an instant response, and batch processing can coexist with it.

The educational benefit becomes clear with a simple correction. If a formula gives the wrong result, a student can change the line, run the program again and test an idea against the new answer. The question being investigated is still fresh in mind. A quick response makes an error part of the learning process rather than another deferred encounter with the computing centre.

Dartmouth did not invent time-sharing on its own. Earlier experiments, notably at MIT, informed the project. DTSS put the idea to work in a widely accessible teaching environment. The origins of operating systems take this question of organising a computing service further; it is separate from the idea of storing a program in memory.

Reading BASIC without mixing up its versions

Short statements and numbered lines

Early BASICs used English words such as PRINT, LET, FOR and NEXT. A small vocabulary reduced how much a beginner needed to learn before a first calculation. It did not remove errors in reasoning or the need to understand the statements.

In early Dartmouth BASIC, a numeric variable’s name was one letter, optionally followed by one digit, such as A or A1. LET A = 3 assigns the value 3 to it. Here, = means assignment, not a mathematical equality to be proved. Expressions combine variables, numbers and operations: +, -, * and / for addition, subtraction, multiplication and division.

Line numbers establish the program’s order and provide destinations for branches. They are not memory addresses. Numbering in steps of ten leaves room to insert a statement. In the working environment, typing a line again with the same number replaces it without requiring the whole program to be re-entered.

IF A > 10 THEN 80 expresses a choice: if the condition holds, execution continues at line 80; otherwise it moves to the next line. GOTO 80 makes the jump unconditionally. A FOR … NEXT loop expresses repetition directly, using a control variable.

GOSUB and RETURN, present in the first Dartmouth BASIC and adopted by many classic dialects, call a sequence of statements and then return to the statement after the call. On its own, this mechanism does not provide the parameters and local variables offered by procedures in more structured languages. Similar vocabulary in two BASICs does not guarantee identical rules.

Interactive does not necessarily mean interpreted

Working at a terminal was interactive from the outset: users entered, edited and ran programs. Yet the first Dartmouth BASIC was compiled. The system translated the program before executing it, hiding the technical steps behind a command such as RUN. A compiler can therefore be part of an interactive experience.

This interaction with the environment must also be distinguished from entering data during execution. Original BASIC used READ and DATA for its data; it did not yet have INPUT. Kurtz places that addition in Dartmouth BASIC’s third edition. The fourth-edition manual, dated January 1968, documents it on pages 50–51. An example using INPUT therefore does not represent the language launched in May 1964.

Two examples that make the reasoning visible

These programs are teaching examples created by Bethemesh, not authentic listings recovered from an archive. The first follows Dartmouth BASIC, fourth edition, January 1968; the second uses constructs documented in the October 1964 manual. The displayed messages use unaccented characters to respect the terminals’ limitations at the time.

Enter a side length, calculate an area, print the result

10 PRINT "SIDE LENGTH ?"
20 INPUT A
30 LET S = A * A
40 PRINT "AREA"
50 PRINT S
60 END

Line 10 displays the request. INPUT A prints its own question mark, waits for a number from the terminal and stores it in A. Line 30 multiplies that value by itself and assigns the result to S. The next two statements print a label and then the calculated number; END finishes the program.

If the input is 4, the expected numeric result is 16. Spacing and the exact representation of the number depend on the system. This example assumes a non-negative side length: it does not yet check whether the input makes geometric sense. Calculating correctly and validating the data are separate tasks.

In the original BASIC without INPUT, the value could instead be supplied within the program using READ A and DATA 4. That would provide input to the calculation, but it would not ask the user a question while the program was running.

Add the first five positive integers

10 LET S = 0
20 FOR I = 1 TO 5
30 LET S = S + I
40 NEXT I
50 PRINT S
60 END

S is an accumulator: it holds the sum calculated so far. The loop gives I the values 1, 2, 3, 4 and 5 in turn. On each pass, line 30 reads the current values, adds them and replaces the previous value of S.

Value of I S before addition S after addition
1 0 1
2 1 3
3 3 6
4 6 10
5 10 15

After the loop, the program prints 15. NEXT I does not mean “repeat forever”: it advances the variable and continues the repetition according to the bound in FOR. Initialising S before the loop is essential to stating the reasoning clearly.

This trace lets a reader check more than the final answer. If the initialisation were missing, or the same value were added twice, the first incorrect pass would become visible.

Beyond Dartmouth: networks, education and dialects

Remote access let other institutions use computing resources without owning the same installation. Dartmouth shared its experience, and General Electric developed commercial services out of the collaboration. BASIC also spread through manufacturers’ adaptations and teaching environments.

The HP 2000F manual of December 1973, for example, describes time-shared BASIC accessed from local terminals or through modems. It shows that before microcomputers, BASIC was already part of commercial shared-computing systems. Its spread did not begin with Microsoft’s interpreters.

What spread was not a fixed object. A dialect adapts or extends a language’s rules: data types, files, character strings, functions or available commands. Dartmouth BASIC’s successive editions also expanded the original; the October 1964 and January 1968 manuals describe different stages.

At Dartmouth, matrix statements prefixed by MAT were among the third edition’s additions and evolved in the fourth. The latter also allowed variables holding character strings. Original BASIC could already print quoted text without having such variables. The fifth edition, whose manual appeared in 1970, added data-file handling. These capabilities should not be attributed to the language of May 1964.

Compatibility therefore has several dimensions. Two systems may accept the same addition but organise files differently. Two machines may both offer PRINT while having incompatible graphics facilities. Understanding a program’s ideas helps when adapting it; it does not automatically make the source file portable.

Microcomputers: BASIC at the keyboard

Altair BASIC: adapting an existing language

In 1975, the Altair 8800 became a landmark in early microcomputing. Bill Gates and Paul Allen helped develop and market a BASIC interpreter for it. They did not invent BASIC: they adapted an already decade-old family of languages to hardware with limited resources. Their careers belong in a separate profile.

An interpreter handles a program’s execution from its representation without requiring the user first to produce a standalone executable. On these machines it offered a way to write calculations and applications quickly. That does not mean it was the only way to use an Altair, or that every basic kit already had the memory and peripherals needed for this experience.

In 1977, different machines and different BASICs

The Apple II, Commodore PET and TRS-80 mark another stage: more immediately usable systems with keyboards, displays and an accessible language. BASIC could be held in ROM, memory that retains its contents when power is switched off. This removed the need to load a compiler from a separate medium before trying a first program.

The Apple II began with Integer BASIC, associated with Steve Wozniak’s work. Applesoft, derived from Microsoft’s BASIC, was a separate development. Microsoft’s adaptations for the 6502 also form part of Commodore BASIC’s history. For the TRS-80, Radio Shack’s 1977 catalogue describes Level I in the machine’s ROM and announces Level II for later: the two variants were not both available at launch.

Memory limitations encouraged compromises. A compact language implementation could leave more room for the user’s program; advanced features required additional code and resources. Graphics, sound and hardware access brought machine-specific extensions. A statement or address that worked on a Commodore was not a universal recipe for an Apple or a TRS-80.

Access at home also changed the pace of learning. People could try a listing, change it and observe what happened without booking time at a computing centre. Schools, manuals and exchanges between users mattered alongside hardware and software publishers. The rise of microcomputers therefore extends beyond any one language or company.

Standards and transformations: several futures for BASIC

Standards sought common ground among dialects. ECMA-55, Minimal BASIC, appeared in January 1978; ECMA-116, BASIC, in June 1986. They define syntax, data and execution rules. A standard specifies a contract: it does not retrospectively make existing machines’ extensions compatible.

A timeline distinguishing Dartmouth in 1964, Altair BASIC in 1975, the microcomputers of 1977, standards in 1978 and 1986, QuickBASIC in 1985, Visual Basic in 1991 and Visual Basic .NET in 2002.

Selected milestones, not drawn to scale. These paths overlap; they are not successive versions of a single product.

In the PC and DOS world, GW-BASIC retained the classic experience of an interpreter with numbered lines. Microsoft preserves a version of its source code from 1983. QuickBASIC, first released in 1985, developed a programming environment with compilation. More structured constructs made systematic line numbering unnecessary.

QBasic, supplied with MS-DOS 5.0 in 1991, is a subset of QuickBASIC 4.5. It offers an editing and interpreted execution environment; QuickBASIC also offers compilation into standalone executables. Their similar names are not two spellings of the same product.

Visual Basic, launched for Windows in 1991, changed the working environment. Developers assembled an interface from controls and wrote code to respond to their events, such as a button click. A program was no longer simply a sequence leading from a keyboard question to END.

VBA, Visual Basic for Applications, is used notably to automate Office applications and manipulate their objects: worksheets, cells, documents and forms. It runs within a host application. Visual Basic .NET, introduced in 2002, belongs to the .NET platform and represents another technical break. Classic BASIC, historical Visual Basic, VBA and Visual Basic .NET share vocabulary and a history, but not all their execution models or libraries.

The criticisms: what happens when a program grows?

A sequence of jumps can be easy to write and hard to follow. If several paths lead to line 200, a reader must find them all to know which values can arrive there. Adding a special case may alter another path. This becomes a practical problem when someone else has to fix the program, or its author returns to it months later.

The criticism of unstructured programming was therefore more than an aesthetic objection to GOTO. It concerned reasoning about parts of a program, limiting the effects of a change and checking possible execution paths. Explicit loops, procedures and local variables provide other ways to organise that reasoning. The history of Pascal explores another educational response to these concerns.

In EWD498, in 1975, Edsger Dijkstra delivered a particularly harsh judgement on habits acquired through learning BASIC, in a polemical text that also attacked other languages. It should not be confused with his famous 1968 criticism of jumps. It documents a debate about education and habits of thought; it does not establish that every BASIC user was incapable of programming well.

Dialect differences matter here too. Pervasive numbering, very short names and subroutines without local variables can make maintenance harder, but these features do not describe the whole family at every stage. BASIC had FOR … NEXT from the beginning, and its later developments introduced other ways to structure code. Teaching practices matter as much as whether a language contains a particular statement.

A legacy rooted in first-hand experience

For many beginners, BASIC was a first encounter with a demanding idea: a machine executes a precise description, whose effects can be observed and corrected. Input, calculations, choices and repetition became operations people could write themselves rather than abstract abilities attributed to “the computer”.

The means changed between Dartmouth and home computers: first sharing a central installation, then having a language on one’s own machine. What connected them was the short distance between an experiment and its result. Visual environments later brought this accessibility to building applications.

That legacy does not diminish other educational languages or the importance of prices, terminals, microprocessors, teachers and software. BASIC was one of the major contributors to this widening of access. Its historical significance lies in combining a language with practical conditions that allowed non-specialists to program.

Frequently asked questions

Can copying a BASIC program help you learn an algorithm?

Yes, if you predict the result, track the values and change a statement to test an idea. Copying alone is not enough. The sum example becomes useful when you understand why the accumulator starts at zero and how each pass changes it.

Why do line numbers often start at 10?

They do not have to. Leaving gaps lets you insert line 15 between lines 10 and 20, for example. The number identifies a position in the program and may be a branch target; it is not a physical memory address.

Can a program without INPUT be used interactively?

Yes. You can edit its data or statements at the terminal, rerun it and read the response. INPUT adds another possibility: supplying data while the program is already executing. This distinction explains the interactivity of Dartmouth’s first environment.

Will an old BASIC listing run in any BASIC?

No. You need to identify the dialect, available functions, number representation and hardware-specific extensions. A simple calculation is easier to adapt than a game that depends on graphics, sound or particular memory addresses.

Does BASIC require an interpreter?

No. The first Dartmouth BASIC used a compiler, while many microcomputers offered interpreters. Other environments combine techniques. Interactivity describes the relationship with the user; it does not dictate a single execution technique.

Is an Excel macro a program in the BASIC of 1964?

No. A VBA macro belongs to a later branch of the family and uses Excel’s object model. It may share keywords with other BASICs, but it does not run in DTSS or reproduce its capabilities and constraints.

Was this article useful?

Sources and references

  1. Dartmouth — The 1960s: hardware, funding and the first DTSS run (opens in a new tab)Page in English
  2. Dartmouth Library — The People Behind the Computer: faculty and student developers (opens in a new tab)Page in English
  3. Thomas E. Kurtz, BASIC (opens in a new tab), History of Programming Languages, Academic Press, pp. 515–537; paper presented at HOPL in 1978, 1981Page in English
  4. Dartmouth College Computation Center, A Manual for BASIC: the elementary algebraic language designed for use with the Dartmouth Time Sharing System (opens in a new tab), Dartmouth College, 1 October 1964; copy preserved by Bitsavers, 1964Page in English
  5. John G. Kemeny and Thomas E. Kurtz, BASIC, Fourth Edition (opens in a new tab), Dartmouth College Computation Center, 1 January 1968; edition prepared with David Cochran, Bitsavers copy, 1968Page in English
  6. Hewlett-Packard, 2000F Time-Shared BASIC Programmer’s Guide (opens in a new tab), Hewlett-Packard, document 02000-90073, December 1973; Bitsavers copy, 1973Page in English
  7. Computer History Museum — 1975: the Altair 8800 and its BASIC interpreter (opens in a new tab)Page in English
  8. Computer History Museum — 1977: Apple II, TRS-80 and Commodore PET (opens in a new tab)Page in English
  9. Centre for Computing History — Apple II: launch and built-in Integer BASIC (opens in a new tab)Page in English
  10. Radio Shack, TRS-80 Microcomputer System, RSC-1 (opens in a new tab), Tandy Corporation, sales catalogue preserved by Color Computer Archive, 1977Page in English
  11. Microsoft — BASIC-M6502: source code and adaptations for 6502 computers (opens in a new tab)Page in English
  12. Microsoft — GW-BASIC: interpreter source code from 1983 (opens in a new tab)Page in English
  13. Microsoft Corporation, Microsoft QuickBASIC 4.5: Language Reference (opens in a new tab), Microsoft, Programmer’s Library copy preserved by PCjs, 1988Page in English
  14. PCjs — Original Microsoft MS-DOS 5.00 disks: QBasic in the 1991 distribution (opens in a new tab)Page in English
  15. Microsoft — Differences Between GW-BASIC and QBasic, Q73084: support article preserved by KnowledgeBase Archive (opens in a new tab)Page in English
  16. Ecma International — ECMA-55, Minimal BASIC, January 1978 (opens in a new tab)Page in English
  17. Ecma International — ECMA-116, BASIC, June 1986 (opens in a new tab)Page in English
  18. Microsoft — The Visual Studio Documentary, Part One: QuickBASIC and Visual Basic milestones (opens in a new tab)Page in English
  19. Microsoft — Getting started with VBA in Office: automation within host applications (opens in a new tab)Page in English
  20. Edsger W. Dijkstra, How do we tell truths that might hurt? (opens in a new tab), EWD498, 18 June 1975, University of Texas at Austin archives, 1975Page in English

Collection

Programming languages

7 / 29

  1. 01Grace Hopper: from early compilers to COBOL
  2. 02John Backus: FORTRAN, BNF, and the rejection of machine code
  3. 03Dennis Ritchie: the C language at the heart of Unix
  4. 04FORTRAN: proving that a compiler could compete with assembly
  5. 05ALGOL: describing and structuring algorithms
  6. 06The C language: making systems portable without hiding the machine
  7. 07BASIC: opening programming to non-specialists
  8. 08SQL: how the relational model changed databases
  9. 09Niklaus Wirth: from Pascal to Oberon, designing through simplicity
  10. 10Bjarne Stroustrup: designing C++ without giving up performance
  11. 11Pascal: learning to program by making structure visible
  12. 12C++: from C with Classes to modern C++
  13. 13Object-oriented programming: objects, messages, and reusable abstractions
  14. 14Guido van Rossum: creating Python to make code readable
  15. 15Brendan Eich: JavaScript, from Netscape prototype to Web standard
  16. 16James Gosling: the engineer behind Java
  17. 17Python: readability, batteries included, and a global ecosystem
  18. 18Java: write once, run anywhere
  19. 19JavaScript: the language that made the Web interactive
  20. 20The history of Rust: memory safety for systems programming
  21. 21John McCarthy: Lisp and the idea of programming with symbols
  22. 22Alan Kay: Smalltalk and the computer as a personal medium
  23. 23Barbara Liskov: the abstraction that made software modular
  24. 24Robin Milner: ML, machine-assisted proof, and languages of interaction
  25. 25Brian Kernighan: AWK, Unix, and the art of explaining code
  26. 26Anders Hejlsberg: from Turbo Pascal to C# and TypeScript
  27. 27Larry Wall: Perl, the language that connected the tools of the Internet
  28. 28Yukihiro Matsumoto: Ruby and programmer happiness
  29. 29Rasmus Lerdorf: PHP and the democratization of the dynamic Web
ReferenceComputing historyBeginner

ALGOL: describing and structuring algorithms

How ALGOL changed program design: an international project, blocks, variable scope, recursion and language reports, from 1958 to Pascal and Simula.

1 November 20269 min