+3
-1
src/main.rs
+3
-1
src/main.rs
···
42
42
43
43
44
44
fn count_bytes(contents: &String) {
45
-
println!("{}", contents.bytes().count())
45
+
println!("{}", contents.bytes().len())
46
46
}
47
47
48
48
fn count_chars(contents: &String) {
···
62
62
yap [-COMMAND] [PATH_TO_FILE]
63
63
64
64
-c, --bytes - count the amount of bytes in a file
65
+
-l, --lines - count the amount of lines in a file
66
+
-w, --words - count the amount of words in a file
65
67
-m, --chars - count the amount of characters in a file
66
68
-h, --help - list the available command line arguments
67
69
"