From fa77ef472f0a7bb6876a018860d653673f99963c Mon Sep 17 00:00:00 2001 From: st529yr Date: Fri, 22 Mar 2024 09:14:57 +0100 Subject: [PATCH] funguje --- cv5/program.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cv5/program.c b/cv5/program.c index 558c607..f399320 100644 --- a/cv5/program.c +++ b/cv5/program.c @@ -60,9 +60,10 @@ int main() { struct Student students[MAX_STUDENTS]; int count = read_and_sum_votes(students, MAX_STUDENTS); + // Ak neexistujú žiadne údaje, vypíšeme chybovú správu if (count == 0) { printf("Nepodarilo nacitat nic\n"); - return 1; + return 0; } // Triedenie študentov