From 13b0a6eb375b90a5e09df3a4c8b15c7806a899d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dami=C3=A1n=20Korpesio?= Date: Sun, 28 Nov 2021 19:00:51 +0100 Subject: [PATCH] prvy --- a2/program.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/a2/program.c b/a2/program.c index 3a8dd13..d15527f 100644 --- a/a2/program.c +++ b/a2/program.c @@ -20,7 +20,7 @@ int main(){ if (r[0] != '{' || r[0] != '(' || r[0] != '[' || r[0] != '<') { //i = n - 2; - //hej = 1; + hej = 1; //puts("halo"); } @@ -63,7 +63,7 @@ int main(){ hej = 4; printf("Read: %s", r); printf("Missing closing brackets: }\n"); - i++; + i = n - 1; } //hodnota = 0; } @@ -88,7 +88,7 @@ int main(){ hej = 4; printf("Read: %s", r); printf("Missing closing brackets: )\n"); - i++; + i = n - 1; } } } @@ -115,7 +115,7 @@ int main(){ hej = 4; printf("Read: %s", r); printf("Missing closing brackets: ]\n"); - i++; + i = n - 1; } } } @@ -139,7 +139,7 @@ int main(){ hej = 4; printf("Read: %s", r); printf("Missing closing brackets: >\n"); - i++; + i = n - 1; } } @@ -167,7 +167,7 @@ int main(){ puts("All brackets OK"); } if (hej == 0){ - printf("Read: %s\nCrossed bracket OK\n", r); + printf("Read: %sCrossed bracket OK\n", r); //printf("%s\n", r); }