Copy stdin to stdout: Difference between revisions
Content added Content deleted
(Solve task in Dart) |
Not a robot (talk | contribs) (Add Draco) |
||
Line 293: | Line 293: | ||
=={{header|Delphi}}== |
=={{header|Delphi}}== |
||
''→ See [[#Pascal|Pascal]]'' |
''→ See [[#Pascal|Pascal]]'' |
||
=={{header|Draco}}== |
|||
<lang draco>\util.g |
|||
proc nonrec main() void: |
|||
char c; |
|||
while |
|||
/* I/O is line-oriented, so first read characters |
|||
* from the current line while that is possible */ |
|||
while read(c) do write(c) od; |
|||
case ioerror() |
|||
/* Then once it fails, if the line is empty, |
|||
* try to go to the next line. */ |
|||
incase CH_MISSING: |
|||
readln(); |
|||
writeln(); |
|||
true |
|||
/* If it failed for another reason (which will be |
|||
* EOF here), stop. */ |
|||
default: |
|||
false |
|||
esac |
|||
do od |
|||
corp</lang> |
|||
=={{header|F_Sharp|F#}}== |
=={{header|F_Sharp|F#}}== |