Browse Source

Möglichkeit hinzugefügt, das Programm zu beenden

remotes/origin/Florian
Florian Baeseler 11 months ago
parent
commit
594fcfe5e9
  1. BIN
      build/test/out/c/casualQuiz.o
  2. BIN
      build/test/out/test_casualQuiz.out
  3. 2
      build/test/results/test_casualQuiz.pass
  4. 2
      build/test/results/test_quizduell.pass
  5. 2
      build/test/results/test_timequiz.pass
  6. 2
      build/test/results/test_wwm.pass
  7. 7
      src/casualQuiz.c

BIN
build/test/out/c/casualQuiz.o

BIN
build/test/out/test_casualQuiz.out

2
build/test/results/test_casualQuiz.pass

@ -66,4 +66,4 @@
- Wrong Input!
- Wrong Input!
- It looks like you havent played the program yet, starting it up...
:time: 0.03260759997647256
:time: 0.035827299987431616

2
build/test/results/test_quizduell.pass

@ -11,4 +11,4 @@
:failed: 0
:ignored: 0
:stdout: []
:time: 0.013434400025289506
:time: 0.016350399993825704

2
build/test/results/test_timequiz.pass

@ -11,4 +11,4 @@
:failed: 0
:ignored: 0
:stdout: []
:time: 0.013458699977491051
:time: 0.01459390000673011

2
build/test/results/test_wwm.pass

@ -11,4 +11,4 @@
:failed: 0
:ignored: 0
:stdout: []
:time: 0.013857100042514503
:time: 0.016387699986808002

7
src/casualQuiz.c

@ -1,6 +1,7 @@
#include <stdio.h>
#include <stdbool.h>
#include <string.h>
#include <stdlib.h>
#include "casualQuiz.h"
@ -51,7 +52,7 @@ bool activePlaying(char* fragen[], char* antworten[], int richtige_antwort[], in
richtig = false;
FzeigeFragen(fragen, i);
FzeigeAntworten(antworten, i);
printf("Please type in your answer 1,2,3 or 4: ");
printf("Reminder: Typing 0 lets you stop the game.\nPlease type in your answer 1,2,3 or 4: ");
eingabe = FEingabeInteger();
richtig = FcheckaufRichtigkeit(eingabe, richtige_antwort, i);
FzaehlernachAuswahl(richtig, answeredP, correctP);
@ -76,6 +77,10 @@ int FEingabeInteger() {
}
bool FcheckaufRichtigkeit(int eingabe, int richtige_antwort[], int i) {
switch (eingabe) {
case 0:{
exit(7);
break;
}
case 1: {
printf("Case 1\n");
if (richtige_antwort[i] == 1) {

Loading…
Cancel
Save