How do I read input from the keyboard?

Tagged:

You can use the special stdin file, which you can also access (if you prefer) as FileStream stdin. Like this:

   line := stdin nextLine

or if you want a number

   n := stdin nextLine asInteger

User login