Variables
Well I need to know how to use variables of other parts like..
This is where the variables are and then I need to use the value of that variables in another part like..
But i get error that the variables are not defined... ani solution?
Code:
int table () {
int bad1 = rand() % 8 + 1;
int bad2 = rand() % 8 + 1;
int bad3 = rand() % 8 + 1;
game ();
}
Code:
int game () {
badl1 = bad1;
badl2 = bad2;
badl3 = bad3;
}