diff options
Diffstat (limited to 'tests/hallo.nim')
-rw-r--r-- | tests/hallo.nim | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/tests/hallo.nim b/tests/hallo.nim deleted file mode 100644 index 070633793..000000000 --- a/tests/hallo.nim +++ /dev/null @@ -1,34 +0,0 @@ -# Hallo world program - -echo("Hi! What's your name?") -var name = readLine(stdin) - -if name == "Andreas": - echo("What a nice name!") -elif name == "": - echo("Don't you have a name?") -else: - echo("Your name is not Andreas...") - -for i in 0..name.len-1: - if name[i] == 'm': - echo("hey, there is an *m* in your name!") - -echo("Please give your password: (12345)") -var pw = readLine(stdin) - -while pw != "12345": - echo("Wrong password! Next try: ") - pw = readLine(stdin) - -echo("""Login complete! -What do you want to do? -delete-everything -restart-computer -go-for-a-walk""") - -case readline(stdin) -of "delete-everything", "restart-computer": - echo("permission denied") -of "go-for-a-walk": echo("please yourself") -else: echo("unknown command") |