Question: C++ Functions 1. Write a program that emulates rolling a die. a) Main handles all input and output. b) Create a function named roll to

C++ Functions
 C++ Functions 1. Write a program that emulates rolling a die.
a) Main handles all input and output. b) Create a function named

1. Write a program that emulates rolling a die. a) Main handles all input and output. b) Create a function named roll to calculate the outcome of a six sided dice roll. - returns the result of a single dice roll. c) Create a second function named roll to calculate dice rolls of a specific dice size. H accept the dice size as a parameter - returns the result of a single dice roll d) Main should output the result of rolling: - a six sided die three times - a 10, 20 and 30 sided die once time each. Example output nput in bold italica) Roll 1 (6): 1 Ro1l 2 (6): 5 Roll 3 (6): 4 Roll 1 (10): 2 Roll 2 (20): 14 Ro11 3 (30): 11 Write a program that requests a number, then outputs its square root rounded up to the nearest integer. a) Main handles all input and output. b) Create a function named sqrtRoundedUp to calculate the number. Use pzedefined emath kibzary functions to handle calculacions. Example Output (input in bold italics) Enter a number: 10 The square root of 10 rounded up to the nearest integer

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!