From 2120ad603f455b59e90d1b405f7924bf361bfe3c Mon Sep 17 00:00:00 2001 From: Ronja Awe Date: Thu, 2 Feb 2023 11:58:02 +0100 Subject: [PATCH] =?UTF-8?q?refactoring:=20Ausgabe=20der=20Funktion=20ge?= =?UTF-8?q?=C3=A4ndert?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/c/labyrinth.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/src/c/labyrinth.c b/src/c/labyrinth.c index 2c40653..ab9038e 100644 --- a/src/c/labyrinth.c +++ b/src/c/labyrinth.c @@ -55,19 +55,21 @@ void labyrinthschritte(lab laby, int hoehe, int breite, int schritte){ int antwort = 0; - for(int i = 0; i < hoehe; i++){ - for(int j = 0; j < breite; j++){ - printf("%c ", laby[i][j]); - } - printf("\n"); - } - printf("\n"); - antwort = 14; if(antwort == schritte){ printf("Richtig, Sie brauchen %d Schritte.\n", schritte); + + for(int i = 0; i < hoehe; i++){ + for(int j = 0; j < breite; j++){ + printf("%c ", laby[i][j]); + } + printf("\n"); + } + printf("\n"); } + + } \ No newline at end of file