Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //this works
- let clean_input = remove_non_chars(input);
- for word in clean_input.split_whitespace() {
- *word_count.entry(word).or_insert(0) += 1;
- }
- //this doesn't
- for word in remove_non_chars(input).split_whitespace() {
- *word_count.entry(word).or_insert(0) += 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement