Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

in haskell 10. 2pts) Convert: isLowerCase :: Char -> Bool isLowerCase x = x `ele

ID: 3711013 • Letter: I

Question

in haskell

10. 2pts) Convert:

isLowerCase :: Char -> Bool
isLowerCase x = x `elem` ['a' .. 'z']

to point free style

11. 4pts) Sort a list of Strings by length of the first word in the strings (if the strings have more than one word)

12. 5pts) Pack repeats in a list of Chars into separate lists, resulting in a sorted list of lists:

12. 5pts) Pack repeats in a list of Chars into separate lists, resulting in a sorted list of lists: E.g., a',' d', 'e', 'e', 'e' 'e'] becomes [ "aaaaaa", "b", "cc", "d", "eeee"]

Explanation / Answer

Prelude> sort['a','a','a','a','b','c','c','a','a','d','e','e','e','e']
Prelude> ['a','a','a','a','a','a']:['b']['c','c']:['d']:['e','e','e','e']

Prelude> zip['a','a','a','a','a','a',b','c','c','d','e','e','e','e']

Prelude> ['a','a','a','a','a','a',b','c','c','d','e','e','e','e']