There isn't straightforward instruction on receiving a string as a variable in the std::io documentation, but I figured this should work:
use std::io;
let line = io::stdin().lock().lines().unwrap();
But I'm getting this error:
src\main.rs:28:14: 28:23 error: unresolved name `io::stdin`
src\main.rs:28 let line = io::stdin.lock().lines().unwrap();
^~~~~~~~~
Why?
I'm using a nightly Rust v1.0.
iowas renamedold_ioafter that release, and it is indeed on the way out, but not yet completely superseded by the newiomodule. First you need to figure out where you stand: Are you using 1.0.0-alpha or are you tracking nightlies?