Difference between revisions of "Input"
From Mesham
Jump to navigationJump to searchm |
|||
Line 9: | Line 9: | ||
#include <io> | #include <io> | ||
− | var f:String; | + | |
− | + | function void main() { | |
− | + | var f:String; | |
+ | input(f); | ||
+ | print("You wrote: "+f+"\n"); | ||
+ | }; | ||
''Since: Version 0.41b'' | ''Since: Version 0.41b'' |
Revision as of 14:35, 15 April 2013
Overview
This input(i) function will prompt the user for input via stdin, the result being placed into i
- Pass: A variable for the input to be written into, of type String
- Returns: Nothing
Example
#include <io> function void main() { var f:String; input(f); print("You wrote: "+f+"\n"); };
Since: Version 0.41b