Question: Fix the syntax errors in the program below. For this problem, you need to create your own Haskell script (.hs file) that contains the program
Fix the syntax errors in the program below. For this problem, you need to create your own Haskell script (.hs file) that contains the program below. N = a div length xs where a = 10 xs = [1,2,3,4,5] There are currently three syntax errors. Report each compile error, and explain how you fixed it (the explanation should be clear and to the point). Once you fix all three errors, change the div function with a division operator /, which will cause a compile error. Report the error, and explain why this error was caused. To do so, look up in the Prelude library how the div function and the division operator (/) are defined.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
