[an error occurred while processing this directive]

Lab Assignment 2 -- BlackJack

  • Only groups of size 2 are allowed to submit Submissions by only 1 person or 3 or more persons will not be accepted by the Fire system.

  • When you are done, please submit your solution using the Fire system.

  • If you are stuck on this assignment, please read the page on Getting Help carefully!
  • Good luck!


    In this lab assignment, you will implement a Haskell program for playing a card game called BlackJack.

    Two Parts

    The lab assignment is divided up into 2 parts. The description of the full lab assignment is here: Lab 2 (BlackJack) (PDF document). The full Task is described in Section 3 of that document.

    The separate parts of this lab assignment are:

    Part A: Task 3.1 (reading the document), Task 3.2 (writing out what happens to the size function), and part of Task 3.3, namely: implement the functions "empty", "value", "gameOver", and "winner".

    Part B: Consists of the remaining tasks described in the lab description.

    Files

    You need the following files:

  • Cards.hs

  • Wrapper.hs
  • Deadlines

    There are seperate deadlines for each of these parts. See the course home page.


    Submission

    The exact instructions on what to submit are stated in the document above.

    Write your answers in one file, called BlackJack.hs. For each assignment, use Haskell comments to indicate what part of the file contains the answer to the assignment. For answers in natural language please use English; write your answers also in Haskell comments. Remove irrelevant things from the file.

    Before you submit your code, Clean It Up! Remember, submitting clean code is Really Important, and simply the polite thing to do. After you feel you are done, spend some time on cleaning your code; make it simpler, remove unneccessary things, etc. We will reject your solution if it is not clean. Clean code:

  • Does not have long lines (< 78 characters)

  • Has a consistent layout

  • Has type signatures for all top-level functions

  • Has good comments

  • Has no junk (junk is unused code, commented code, unneccessary comments)

  • Has no overly complicated function definitions

  • Does not contain any repetitive code (copy-and-paste programming)
  • Please do not submit the modules Cards.hs and Wrapper.hs.

    When you are done, please submit it using the Fire system.

    Good luck!