Skip to content

Commit 57c48af

Browse files
authored
Fixed typos in src/string/isogram.rs (#946)
1 parent e877687 commit 57c48af

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/string/isogram.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ fn count_letters(s: &str) -> Result<HashMap<char, usize>, IsogramError> {
5656
/// # Return
5757
///
5858
/// - `Ok(true)` if all characters appear only once, or `Ok(false)` if any character appears more than once.
59-
/// - `Err(IsogramError::NonAlphabeticCharacter) if the input contains any non-alphabetic characters.
59+
/// - `Err(IsogramError::NonAlphabeticCharacter)` if the input contains any non-alphabetic characters.
6060
pub fn is_isogram(s: &str) -> Result<bool, IsogramError> {
6161
let letter_counts = count_letters(s)?;
6262
Ok(letter_counts.values().all(|&count| count == 1))
@@ -89,7 +89,7 @@ mod tests {
8989
isogram_sentences: ("The big dwarf only jumps", Ok(true)),
9090
isogram_french: ("Lampez un fort whisky", Ok(true)),
9191
isogram_portuguese: ("Velho traduz sim", Ok(true)),
92-
isogram_spanis: ("Centrifugadlos", Ok(true)),
92+
isogram_spanish: ("Centrifugadlos", Ok(true)),
9393
invalid_isogram_with_repeated_char: ("hello", Ok(false)),
9494
invalid_isogram_with_numbers: ("abc123", Err(IsogramError::NonAlphabeticCharacter)),
9595
invalid_isogram_with_special_char: ("abc!", Err(IsogramError::NonAlphabeticCharacter)),

0 commit comments

Comments
 (0)