From 94423e22b3d8a30520b57580c3363fef1db33345 Mon Sep 17 00:00:00 2001 From: Bohdan Yanchyk Date: Thu, 9 Apr 2020 23:12:07 +0000 Subject: [PATCH] =?UTF-8?q?Aktualizovat=20=E2=80=9Edu5/program.c=E2=80=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- du5/program.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/du5/program.c b/du5/program.c index 8c9e26a..b2add96 100644 --- a/du5/program.c +++ b/du5/program.c @@ -81,10 +81,15 @@ int main(){ } } - c-=(k+1); - + + if(c>1){ + k--; + } + else{ + k=1; + } printf("Vysledky:\n"); - for(int i =0;i<=c;i++){ + for(int i =0;i