|
@ -8,6 +8,13 @@ int generateRandomNumber(int min, int max) { |
|
|
return rand() % (max - min + 1) + min; |
|
|
return rand() % (max - min + 1) + min; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
int getUserAnswer() { |
|
|
|
|
|
int userAnswer; |
|
|
|
|
|
scanf("%d", &userAnswer); |
|
|
|
|
|
return userAnswer; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Funktion zum Durchführen des Mathematikspiels |
|
|
// Funktion zum Durchführen des Mathematikspiels |
|
|
void runMathGame(int rounds) { |
|
|
void runMathGame(int rounds) { |
|
|
int correctAnswers = 0; |
|
|
int correctAnswers = 0; |
|
|