summaryrefslogtreecommitdiff
path: root/rust
diff options
context:
space:
mode:
authorKjetil Orbekk <kjetil.orbekk@gmail.com>2016-06-09 19:00:20 -0400
committerKjetil Orbekk <kjetil.orbekk@gmail.com>2016-06-09 19:00:20 -0400
commitbd52727d465a777ee749b6649ca768ffe7e900b0 (patch)
tree831975b48c6fb00c434582a2d14a5a2db4ea2f4d /rust
parentb0774a09f67ee2da51b290ba625cc407be8b2518 (diff)
Hello, Rust!
Diffstat (limited to 'rust')
-rw-r--r--rust/hello.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/rust/hello.rs b/rust/hello.rs
new file mode 100644
index 0000000..851beed
--- /dev/null
+++ b/rust/hello.rs
@@ -0,0 +1,6 @@
+use std::io;
+fn main() {
+ let mut name = String::from("World");
+ io::stdin().read_line(&mut name).ok();
+ println!("Hello, {}", name);
+}