Get Instant Help From 5000+ Experts For
question

Writing: Get your essay and assignment written from scratch by PhD expert

Rewriting: Paraphrase or rewrite your friend's essay with similar meaning at reduced cost

Editing:Proofread your work by experts and improve grade at Lowest cost

And Improve Your Grades
myassignmenthelp.com
loader
Phone no. Missing!

Enter phone no. to receive critical updates and urgent messages !

Attach file

Error goes here

Files Missing!

Please upload all relevant files for quick & complete assistance.

Guaranteed Higher Grade!
Free Quote
wave
20COA108-Functional Programming

Task

The coursework is divided into four parts.  which contains all the Haskell code and explanations.

Part 1

a) List and explain (in your own words) 3 benefits that Functional Programming brings to programmers.

b) Explain in your own words what a (mathematical) function is and discuss to what extent Haskell functions resemble mathematical functions

c) Explain what a higher-order function is (use examples to support your answer);

Part 2

(a) Define a function steps that takes three positive Int values m n p and returns a String that can be displayed as p steps, of height m and width n, the right way up, and repeats the pattern in opposite way.

(b) Define a function flagpattern that takes two positive Int values n greater than or equal to 5, and m greater than or equal to 1, and returns a String that can be displayed as the following m 'flag' patterns of dimension n.

Part 3

Define a function compatibility, that takes two String values representing persons names, and outputs their compatibility 

Part 4

Define a polymorphic function lsplit that is applied to two arguments of types [a] and a, where a is a type on which == is defined, and partitions the original list at occurrences of the second argument and returns a list of int values of the number of elements for each part

support
close