diff options
| author | Yudai Kawabuchi <yudaikawabuchi@gmail.com> | 2024-08-01 09:47:50 +0900 |
|---|---|---|
| committer | Yudai Kawabuchi <yudaikawabuchi@gmail.com> | 2024-08-01 09:47:50 +0900 |
| commit | dacdce1ea245523bf7bf380f91bff76e7f867315 (patch) | |
| tree | 2cd228f3c8eb26d53491c90222a81493cdfb3484 /exercises | |
| parent | 766f3c50ec20c9b3fbf95bddf9fc095ce65cef78 (diff) | |
fix: update struct name in hashmap3
Diffstat (limited to 'exercises')
| -rw-r--r-- | exercises/11_hashmaps/hashmaps3.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/exercises/11_hashmaps/hashmaps3.rs b/exercises/11_hashmaps/hashmaps3.rs index 9f8fdd7..7e9584d 100644 --- a/exercises/11_hashmaps/hashmaps3.rs +++ b/exercises/11_hashmaps/hashmaps3.rs @@ -10,12 +10,12 @@ use std::collections::HashMap; // A structure to store the goal details of a team. #[derive(Default)] -struct Team { +struct TeamScores { goals_scored: u8, goals_conceded: u8, } -fn build_scores_table(results: &str) -> HashMap<&str, Team> { +fn build_scores_table(results: &str) -> HashMap<&str, TeamScores> { // The name of the team is the key and its associated struct is the value. let mut scores = HashMap::new(); |
