You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
10 lines
317 B
Rust
10 lines
317 B
Rust
3 years ago
|
use std::io::{self, Write};
|
||
|
fn main() {
|
||
|
//Create a memory buffer to read from file
|
||
|
let mut buffer = String::new();
|
||
|
// read a line into the buffer
|
||
|
let _ = io::stdin().read_line(&mut buffer).unwrap();
|
||
|
// Write the buffer to standard output
|
||
|
io::stdout().write(&mut buffer.as_bytes()).unwrap();
|
||
|
}
|