C++ Lab Exercises
Name your projects according to this template: #'Lab2_#'
where the '#' is the number of the challenge.
-
Write a program that flips a coin 100 times and then tells you the number of heads and tails.
-
Translate the Guess My Number game from our book into a working C++ program.
-
Create a simple die rolling app. Below is a sample of how the program should run.
- WELCOME to *
-
Die -Roller! *
-
*
- Instructions: *
- To roll, type the number of dice, then the number *
- of sides then any modifiers, all separated by *
- spaces. *
-
*
- like this: 3 6 -1 *
- that would mean: *
- Roll 3 6-sided dice, and subtract 1 from each die *
-
*
- To exit, enter: 1 1 1 *
- ENJOY! *
Your Roll: 4 6 0
Results: 5 2 4 Total: 11
Your Roll: 1 1 1
Thank you, Have a nice day.