Rutgers ALGOL 68: Difference between revisions

m
Line 32:
<br><br>
The read procedure handles '''char''' and '''string''' items differently to the standard.<br>
read( ( c ) ), where c is a '''char''' item gets the next character from standard input - it c is set to '''repr''' 10 at end of line.
<br>
read( ( s ) ), where s is a '''string''' item does not change the bounds of s, it reads as many characters as are currently contained in s, - so '''string''' s; read( ( s, newline ) ) won't read anything into s as its bounds will be 1:0 at that point.
3,021

edits