Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Write a C++ program that will prompt the user for the number of times the progra

ID: 3624972 • Letter: W

Question

Write a C++ program that will prompt the user for the number of times the program should roll a die. Your program then rolls the die (generate a number between 1 and 6 inclusive) the requested number of time and counts the occurrence of each number. It finally prints out a list giving the frequency of each outcome, as well as the percentage each occurrence represents of the total number of rolls. Following is a sample output screens. The count of the occurrence of each role should be stored in an array with 6 elements.

------------------------------------
Welcome to the Roll Counter
------------------------------------
How many times do you want me to roll the die? 1000
RESULTS
---------
ROll Frequency Percentage
1 177 17.70
2 175 17.50
3 154 15.40
4 159 15.90
5 179 17.90
6 156 15.60
Done!

Explanation / Answer

#include #include using namespace std; int main(){ int num, rolls; int dice[6] = {0}; cout
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote