Measures Concepts
GitHub icon

BALGOL

BALGOL - Programming language

< >

BALGOL is a programming language created in 1959 by Bob Barton.

#1523on PLDB 65Years Old


Example from the web:
INTEGER I..., J..., K..., L..., M..., N...$ BOOLEAN KEEP, LAST$ REAL MAT..., JOULES$ REAL OTHERWISE$ FUNCTION TORADS(DEGREES) = DEGREES . 3.1415926/180$ FUNCTION PYTHAGOREAN(A, B) = SQRT(A*2 + B*2)$ FOR I = 1, 3, 5, 7, 11, (13, 7, 99), 101, (103, 1, 125)$ A(I) = I$ UNTIL A > 125 OR OUTTAHERE$ BEGIN OUTTAHERE = A EQL 77$ A = A + 3 END$

Language features

Feature Supported Token Example
Conditionals ✓
EITHER IF A > B$ FWD = 1$ OTHERWISE$ FWD = 0$
Assignment ✓
ALPHA = BETA = GAMMA = 2DELTA + 1$
Expressions ✓
ALPHA + BETA / GAMMA
Functions ✓
FUNCTION TORADS(DEGREES) = DEGREES . 3.1415926/180$
Lists ✓
ARRAY MONTHDAYS(12) = (31,28,31,30,31,30,31,31,30,31,30,31)$
Booleans ✓
Floats ✓
Integers ✓

View source

- Build the next great programming language · Search · Add Language · Features · Creators · Resources · About · Blog · Acknowledgements · Queries · Stats · Sponsor · Day 605 · feedback@pldb.io · Logout