Write a calculating function that uses a for loop to “roll” N random numbers, each between 1 and 6. It then returns to the caller the percentage of rolls on which we rolled an odd number bigger than X. This is what i have so far.....
1 2 3 4 5 6 7 8 9 10 11
double percentageOdds(int N, int X) {
int oddsX = 0;
}
int main() {
double p;
p = percentageOdds(1000, 3);
cout << “I tossed 1000 dice, and “ << x << “ times I got an odd number bigger than 3.” << endl;
system(“pause”);
}