Created
February 10, 2021 01:08
-
-
Save tail-call/a42dd858e1eaa93153b9828ffef924ec to your computer and use it in GitHub Desktop.
Designing a programming language that looks old...
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ALGORITHM SHOW MESSAGE | |
PARAMETERS T$ | |
VARIABLES D<>; M<> | |
START | |
10 IF T$ .EQ NULL THEN GOTO 70 | |
20 PARAMETERS T$ | |
30 CALL "createElement" OF DOCUMENT INTO D<> | |
40 SET "innerHTML" OF D<> TO T$ | |
50 PARAMETERS "#messageArea" | |
60 CALL "querySelector" OF DOCUMENT INTO M<> | |
70 PARAMETERS D<> | |
80 CALL "appendChild" of M<> INTO VOID | |
90 SETUP UNDEFINED | |
END | |
ALGORITHM MAIN | |
PARAMETERS VOID | |
VARIABLES DEFAULT | |
START | |
10 PARAMETERS "Hello world!" | |
20 INVOKE SHOW MESSAGE | |
30 GOTO 10 AFTER 10 SECONDS | |
END |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment