Lab 4 help--functions

My teacher was really opaque on the directions for this lab. So, I rewrote the directions in the way I understand them, and am hoping anyone in the online community will help me.


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/*
Directions: We are developing a multi-player game;  Each player gets n chances--and n is defined by 11; each turn (or chance) the player tosses a coin; if he rolls a head, he gets to roll the dice; if he rolls a tail, he forfeits the chance and earns a zero.
write a function called myGame to implement this game.
input arguments: n = number of chances
output/return arguments: total = from summation of dice rolls.
Now call your function for 2-players.
Calculate player 1's total

Calculate player 2's total

The highest score wins. Display a message to the winner.
*/



//The basic setup looks like this: 

#include <iostream>
#include <cmath>
#include <ctime>
using namespace std;

int myRandNumGen(){
    int num = rand();
        num => 6
    return num;
}

int diceRoll(){
    int dice = myRandNumGen() % 6 +1;
    
}

char coinTossFunction( ){
    
}

double calcAverageDice(int n){
	10 = number of dice rolls
	
}

double calcAverageCoin(int n){
	
}

	
    return 0;
}

will help me.

Help you with what? With writing your assignment instead of you?
anyways what is line 39 supposed to be doing
Topic archived. No new replies allowed.