COSC LAB WORK Haskell 10/10/2017 Due First five due in lab, All 11 due on 10/12/2017 FIVE OF THE FOLLOWING ARE DUE TODAY. You may work with a partner. One demo (of all five) per person. 1. Express the list [16, 4, 32] using the cons operator, the numbers 16, 4, 32 and the empty list. (No other operators, no other numbers) 2. Given a list, [1, 2, 3], express the cons operator in terms of head and tail. That is, write a cons' function that uses head and tail to produce the resulting list cons' 'a' "BCD" produces "aBCD" 3. Create a function makeEmpties x, that will create a list containing x empty lists. makeEmpties 3 produces [ [], [], [] ] 4. What is the type of function zip? 5. Give three ways to produce [1, 3, 5]. (Just outputting [1, 3, 5] doesn't count. You must use at least one operator.) 6. Use list comprehension to output a list containing all the even numbers in an input list of ints. 7. Use list comprehension to output all vowels in an input string. 8. Write a function that uses list comprehension to output the list of all the 2-tuples where the first member of the tuple is an element from the input parameter range, and the second is the square of the first element. The second must also be in the input range. E.g., f [1..20] outputs [ (1, 2), (2, 4), (3, 9), (4, 16) 9. Create a function f x. x is a 5-tuple. f returns the first element. 10. Write a function tail' that uses pattern matching to produce the tail of a list. E.g., tail' [1, 2, 3] outputs [2, 3] The function definition must be in the spirit (using pattern matching) of the definition of head' on page 38. You cannot use tail. 11. Give the recursive definition of the fibonacci function (See the example definition of the factorial function, page 36.)