From b37745690a86ad2fddbc85a5a239ce4cdf15ca40 Mon Sep 17 00:00:00 2001 From: Pascal Schneider Date: Mon, 5 Feb 2024 23:22:38 +0100 Subject: [PATCH] =?UTF-8?q?For-Schleife=20f=C3=BCr=20Fragen=20Shuffle=20v2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build/test/out/test_quizduell.out | Bin 101212 -> 101212 bytes build/test/out/test_wwm.out | Bin 101188 -> 101188 bytes build/test/results/test_casualQuiz.pass | 2 +- build/test/results/test_quizduell.pass | 2 +- build/test/results/test_timequiz.pass | 2 +- build/test/results/test_wwm.pass | 2 +- src/timequiz.c | 13 +++++++++++++ 7 files changed, 17 insertions(+), 4 deletions(-) diff --git a/build/test/out/test_quizduell.out b/build/test/out/test_quizduell.out index 56428e278884e988d4cf3af17136a9cc991ed0fb..fbafff56f307abbb0350555552a3cdb1a6a614b6 100755 GIT binary patch delta 25 hcmcaJjqT1fwh0|fYB3YL{Ft?tGB)1cdYiGa3jm8^3c&yX delta 25 hcmcaJjqT1fwh0|f-Ubu9{FwbJnHq0zz0KIz1ptcz3bOzJ diff --git a/build/test/out/test_wwm.out b/build/test/out/test_wwm.out index a4c954c67f30445e558b50aeff59a744aafd4987..70a210f1e34f276fb54a20b9cc8b4d744ea952c1 100755 GIT binary patch delta 25 hcmX>yjqS)Zwh0|f>M;|${FtxLWNf^>^)_Q>7XXbg3mX6c delta 25 hcmX>yjqS)Zwh0|f(#8|J{FqM_Fg4!ZdYdt`3jl~73b6nH diff --git a/build/test/results/test_casualQuiz.pass b/build/test/results/test_casualQuiz.pass index 66b0ab1..e85cee3 100644 --- a/build/test/results/test_casualQuiz.pass +++ b/build/test/results/test_casualQuiz.pass @@ -11,4 +11,4 @@ :failed: 0 :ignored: 0 :stdout: [] -:time: 0.03200719999995272 +:time: 0.01796970000032161 diff --git a/build/test/results/test_quizduell.pass b/build/test/results/test_quizduell.pass index 240e582..fb42ca9 100644 --- a/build/test/results/test_quizduell.pass +++ b/build/test/results/test_quizduell.pass @@ -11,4 +11,4 @@ :failed: 0 :ignored: 0 :stdout: [] -:time: 0.02661990000001424 +:time: 0.014309700000012526 diff --git a/build/test/results/test_timequiz.pass b/build/test/results/test_timequiz.pass index ec2613c..f929b3d 100644 --- a/build/test/results/test_timequiz.pass +++ b/build/test/results/test_timequiz.pass @@ -11,4 +11,4 @@ :failed: 0 :ignored: 0 :stdout: [] -:time: 0.024552200000016455 +:time: 0.014682400000310736 diff --git a/build/test/results/test_wwm.pass b/build/test/results/test_wwm.pass index 47e9179..fdf9ca4 100644 --- a/build/test/results/test_wwm.pass +++ b/build/test/results/test_wwm.pass @@ -11,4 +11,4 @@ :failed: 0 :ignored: 0 :stdout: [] -:time: 0.02601670000001377 +:time: 0.014739700000063749 diff --git a/src/timequiz.c b/src/timequiz.c index 9e53409..84b8e8f 100644 --- a/src/timequiz.c +++ b/src/timequiz.c @@ -26,5 +26,18 @@ void timequiz() { char* temp = answers[i][0]; answers[i][0] = answers[i][j]; answers[i][j] = temp; + + if (j == 0) { + correctAnswers[i] = 1; + } + else if (j == 1) { + correctAnswers[i] = 2; + } + else if (j == 2) { + correctAnswers[i] = 3; + } + else { + correctAnswers[i] = 4; + } } }