<commit_before>module Bob (responseFor) where

import Data.List
import Data.Char

responseFor :: String -> String
responseFor said | silence said = "Fine. Be that way!"
                 | shout said = "Woah, chill out!"
                 | question said = "Sure."
                 | otherwise = "Whatever."
                   
silence :: String -> Bool
silence [] = True
silence said = all (\x -> x == ' ') said

shout :: String -> Bool
shout said = said == map toUpper said

question :: String -> Bool
question said = isSuffixOf "?" said<commit_msg>:goat: Haskell Bob - Passes all tests<commit_after>module Bob (responseFor) where

import Data.Char

responseFor :: String -> String
responseFor said | silence said = "Fine. Be that way!"
                 | shout said = "Woah, chill out!"
                 | question said = "Sure."
                 | otherwise = "Whatever."
                   
silence :: String -> Bool
silence said = all isSpace said

shout :: String -> Bool
shout said = (any isAlpha said) && not (any isLower said)

question :: String -> Bool
question said = (last said) == '?'
{'fraction_non_alphanumeric': 0.11668185961713765, 'fraction_numerical': 0.0, 'mean_word_length': 2.287425149700599, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 12, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '872602', 'n_tokens_mistral': 308, 'n_tokens_neox': 293, 'n_words': 114}