Programming Problem, Please help!!!
Here's the instructions for a program I am having trouble with, please help if you can.
Instructions: Write a program that simulates the rolling of two dice. The program should use rand to roll the first die, and should use rand again to roll the second die. The sum of the two values should then be calculated. [Note: Since each die can show an integer value will vary from 2 to 12 with 7 being the most frequent sum and 2 and 12 being the least frequent sums.] There are 36 possible combinations of the two dice. Your program should roll the two dice 36,000 times. Use a single-subscripted array to tally the numbers of times each possible sum appears. Print the results in a tabular format. Also, determine if the totals are reasonable; ie., there are six ways to roll a 7, so approximately one sixth of all the rolls should be 7.
Here's what I have so far:
What I am having trouble with is figuring out how to set up arrays so it will display the different odds for each number (eg. 7 being the most frequent, and 2 and 12 being the least frequent). I also cannot figure out how to calculate the percentages for the last two columns (expected and actual), so if anybody can please help with that I'd very much appreciate it.
Btw, if you dont know anything about this, please don't comment with something like "I dont know anything about programming" or "let someone else help you, I'm stumped" or something pointless like that. No offense, but its a little frustrating to get a comment and think someone has a solution to my programming problem, but they are just saying "Its all Greek to me" or something stupid like that. Not to sound mean but this is serious business and I'm kinda worried that I'm not going to be able to figure this out and possibly fail Programming.