RosettaCodeData/Task/Flow-control-structures/Nim/flow-control-structures-2.nim
2016-12-05 23:44:36 +01:00

7 lines
118 B
Nim

var f = open "input.txt"
try:
var s = readLine f
except ReadIOEffect:
echo "An error occured!"
finally:
close f