Skip to content

Instantly share code, notes, and snippets.

@Eternity-Yarr
Created June 8, 2017 06:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Eternity-Yarr/b09c5190542989ce88925192624089bd to your computer and use it in GitHub Desktop.
Save Eternity-Yarr/b09c5190542989ce88925192624089bd to your computer and use it in GitHub Desktop.
use std::io::BufReader;
use std::io::BufRead;
use std::fs::File;
fn main() {
let file = File::open("main.rs").unwrap();
let reader = BufReader::new(file);
for line in reader.lines()
.filter_map(|x| x.ok()) {
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment