Skip to content

Commit f2ad3a6

Browse files
authored
Merge pull request #697 from WowSuchRicky/main
Rename 'Lichi' to 'Lychee' in the fruit example
2 parents caf921a + b790baf commit f2ad3a6

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

exercises/collections/hashmap2.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
// represents the name of the fruit and the value represents how many
55
// of that particular fruit is in the basket. You have to put *MORE
66
// THAN 11* fruits in the basket. Three types of fruits - Apple (4),
7-
// Mango (2) and Lichi (5) are already given in the basket. You are
7+
// Mango (2) and Lychee (5) are already given in the basket. You are
88
// not allowed to insert any more of these fruits!
99
//
1010
// Make me pass the tests!
@@ -21,7 +21,7 @@ enum Fruit {
2121
Apple,
2222
Banana,
2323
Mango,
24-
Lichi,
24+
Lychee,
2525
Pineapple,
2626
}
2727

@@ -30,7 +30,7 @@ fn fruit_basket(basket: &mut HashMap<Fruit, u32>) {
3030
Fruit::Apple,
3131
Fruit::Banana,
3232
Fruit::Mango,
33-
Fruit::Lichi,
33+
Fruit::Lychee,
3434
Fruit::Pineapple,
3535
];
3636

@@ -49,7 +49,7 @@ mod tests {
4949
let mut basket = HashMap::<Fruit, u32>::new();
5050
basket.insert(Fruit::Apple, 4);
5151
basket.insert(Fruit::Mango, 2);
52-
basket.insert(Fruit::Lichi, 5);
52+
basket.insert(Fruit::Lychee, 5);
5353

5454
basket
5555
}
@@ -60,7 +60,7 @@ mod tests {
6060
fruit_basket(&mut basket);
6161
assert_eq!(*basket.get(&Fruit::Apple).unwrap(), 4);
6262
assert_eq!(*basket.get(&Fruit::Mango).unwrap(), 2);
63-
assert_eq!(*basket.get(&Fruit::Lichi).unwrap(), 5);
63+
assert_eq!(*basket.get(&Fruit::Lychee).unwrap(), 5);
6464
}
6565

6666
#[test]

0 commit comments

Comments
 (0)