Module Outline

Use the following resources and work with your mentor to master the objectives for this module. Practice by completing the Mini-Project, Project, and Challenges.

Stretch Problem

    Enums: Rock, Paper, Scissors

    1. create two separate enums. one called HandShape that has cases of rock, paper, and scissors. The other called MatchResult that has match results win, lose, draw.
    2. Create a function called match that takes two handShapes as parameters and returns a matchResult. Cover all cases.
    3. Print out results of several matches.

    ♦ Black Diamond

    Create a new project for a Rock, Paper, Scissors app (you've had this black diamond before, but now with a different twist). This will be a single-view app with three buttons. One will say Rock, one will say Paper, one will say Scissors. When the user taps on a button, you will randomly determine what the computer plays, and announce to the user whether the user wins, loses, or ties. You must incorporate the enums and function you made above. Once this is completed and working, find a way to simulate the computer getting better over time (i.e. they get better at guessing your move after playing a few games).

  • Hint
  • Solution

Project

  • Unit 2 Assessment

    This assessment is designed to help you practice using what you learned in this Unit. You will have to use UIAlertControllers, Core Data, and intermediate table view concepts, including a custom UITableViewCell and a protocol.

Mastery Review

Module 15 - Flex - Debugging
  • Expand all
  • Collapse all
  • Enums: Rock, Paper, Scissors stretch problem