Skip to content

Commit 387b7eb

Browse files
committed
update
1 parent 42df75e commit 387b7eb

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

exercises/strings/strings1.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@
55
// Execute `rustlings hint strings1` or use the `hint` watch subcommand for a
66
// hint.
77

8-
// I AM NOT DONE
8+
99

1010
fn main() {
1111
let answer = current_favorite_color();
1212
println!("My current favorite color is {}", answer);
1313
}
1414

1515
fn current_favorite_color() -> String {
16-
"blue"
16+
String::from("blue")
1717
}

exercises/strings/strings2.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@
55
// Execute `rustlings hint strings2` or use the `hint` watch subcommand for a
66
// hint.
77

8-
// I AM NOT DONE
8+
99

1010
fn main() {
1111
let word = String::from("green"); // Try not changing this line :)
12-
if is_a_color_word(word) {
12+
if is_a_color_word(&word) {
1313
println!("That is a color word I know!");
1414
} else {
1515
println!("That is not a color word I know.");

0 commit comments

Comments
 (0)