Question

Implementation, Test File and Report

In addition to your solutions to these programming challenges, you are asked to submit an additional

Tests.hs file with your own tests, and a report:

You are expected to test your code carefully before submitting it and we ask that you write a report

on your development strategy. Your report should include an explanation of how you implemented

and tested your solutions. Your report should be up to 1 page (400 words). Note that this report is

not expected to explain how your code works, as this should be evident from your commented code

itself. Instead you should cover the development and testing tools and techniques you used, and

comment on their effectiveness.

Your report should include a second page with a bibliography listing the source(s) for any fragments

of code written by other people that you have adapted or included directly in your submission.

Submission and Marking

Your Haskell solutions should be submitted as a single plain text file Challenges.hs. Your tests should

also be submitted as a plain text file Tests.hs that includes a main function. Finally, your report

should be submitted as a PDF file, Report.pdf.

The marking scheme is given in the appendix below. There are up to 5 marks for your solution to

each of the programming challenges, up to 5 for your explanation of how you implemented and

tested these, and up to 5 for your coding style. This gives a maximum of 40 marks for this

assignment, which is worth 40% of the module.

Your solutions to these challenges will be subject to automated testing so it is important that you

adhere to the type definitions and type signatures given in the supplied dummy code file

Challenges.hs. Do not change the list of functions and types exported by this file. Your code will be

run using a command line such as stack ghc -e "main" CW2Tests.hs, where CW2Tests.hs imports

Challenge.hs. You should check before you submit that your solution compiles and runs as expected.

The supplied Parsing.hs file will be present so it is safe to import this and any library included in the

standard Haskell distribution (Version 7.6.3). Third party libraries will not be present so do not

import these. Your own test cases in the submitted file Tests.hs will also be run using a similar

command line, so make sure this file defines a suitable main function that runs your tests and

reports the results.

Fig: 1