ALGOL 68/prelude: Difference between revisions

lang -> syntaxhighlight
No edit summary
(lang -> syntaxhighlight)
Line 49:
<br/>
Here is a version for other implementations of Algol 68:
<langsyntaxhighlight lang=algol68># A string in string procedure for use with compilers other than Algol 68G #
# returns TRUE if s is in t, FALSE otherwise. #
# if pos is not NIL: #
Line 81:
OD;
found
FI # string in string # ;</langsyntaxhighlight>
 
=== aArray.a68 ===
An associative array MODE for STRING keys and values. This is used by a number of Rosseta Code tasks.
<langsyntaxhighlight lang=algol68># associative array for STRING elements and keys #
 
# the modes allowed as associative array element values - change to suit #
Line 96:
 
PR read "aArrayBase.a68" PR
</syntaxhighlight>
</lang>
 
=== aArrayBase.a68 ===
Line 102:
<br>An item "init element value" must also be defined.
<br>If AAKEY is not STRING, a suitable HASH operator will also need to be defined.
<langsyntaxhighlight lang=algol68># associative array handling using hashing #
# AAKEY and AAVALUE modes and OP HASH(AAKEY)INT must be defined to use this #
 
Line 238:
FI
END; # NEXT #
</syntaxhighlight>
</lang>
 
=== URI Parser ===
3,038

edits