Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
ALGOL
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
===Timeline: Hello world=== The variations and lack of portability of the programs from one implementation to another is easily demonstrated by the classic [[hello world program]].{{citation needed|date = February 2024}} ====ALGOL 58 (IAL)==== {{main|ALGOL 58}} ALGOL 58 had no I/O facilities. ====ALGOL 60 family==== {{main|ALGOL 60}} Since ALGOL 60 had no I/O facilities, there is no portable [[hello world program]] in ALGOL. The next three examples are in Burroughs Extended Algol. The first two direct output at the interactive terminal they are run on. The first uses a character array, similar to C. The language allows the array identifier to be used as a pointer to the array, and hence in a REPLACE statement. {{sxhl|2=m2|1= BEGIN FILE F(KIND=REMOTE); EBCDIC ARRAY E[0:11]; REPLACE E BY "HELLO WORLD!"; WRITE(F, *, E); END. }} A simpler program using an inline format: {{sxhl|2=m2|1= BEGIN FILE F(KIND=REMOTE); WRITE(F, <"HELLO WORLD!">); END. }} An even simpler program using the Display statement. Note that its output would end up at the system console ('SPO'): {{sxhl|2=m2|1= BEGIN DISPLAY("HELLO WORLD!") END.}} An alternative example, using Elliott Algol I/O is as follows. Elliott Algol used different characters for "open-string-quote" and "close-string-quote", represented here by {{color box|rgba(255,255,255,0)|border=silver|[[‘]]}} and {{color box|rgba(255,255,255,0)|border=silver|[[Single quotation mark|’]]}}. {{sxhl|2=pascal|1= program HiFolks; begin print ‘Hello world’ end; }} Below is a version from Elliott 803 Algol (A104). The standard Elliott 803 used five-hole paper tape and thus only had upper case. The code lacked any quote characters so £ (UK Pound Sign) was used for open quote and ? (Question Mark) for close quote. Special sequences were placed in double quotes (e.g£. £L?? produced a new line on the teleprinter). HIFOLKS' BEGIN PRINT £HELLO WORLD£L??' END' The [[ICT 1900 series]] Algol I/O version allowed input from paper tape or punched card. Paper tape 'full' mode allowed lower case. Output was to a line printer. The open and close quote characters were represented using '(' and ')' and spaces by %.<ref>{{cite web|url=http://www.icl1900.co.uk/techpub/tp3340.djvu|title=ICL 1900 series: Algol Language|publisher=ICL Technical Publication 3340|year=1965}}</ref> 'BEGIN' WRITE TEXT('('HELLO%WORLD')'); 'END' ====ALGOL 68==== {{main|ALGOL 68}} '''ALGOL 68''' code was published with reserved words typically in lowercase, but bolded or underlined. '''begin''' printf(($gl$,"Hello, world!")) '''end''' In the language of the "Algol 68 Report" the [[input/output]] facilities were collectively called the "Transput".
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
ALGOL
(section)
Add topic