From 6ad25f37c1cb9a3f0d0d1427a1c235917f538f68 Mon Sep 17 00:00:00 2001 From: Andrii Hermaniuk Date: Fri, 18 Mar 2022 14:41:54 +0100 Subject: [PATCH] aaaa --- du3/program.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/du3/program.c b/du3/program.c index 6b0f4e0..42161c8 100644 --- a/du3/program.c +++ b/du3/program.c @@ -11,7 +11,7 @@ int main(){ for(int idx=0;1;idx++ ){ ch=getchar(); if(ch==EOF||ch==' ')break; - if((ch<'9'&&ch>'0')||(ch==EOF)||(ch==' ')); + if((ch<'9'&&ch>'0')||(ch==EOF)||(ch==' ')||ch=='\n'); else printf("Nepodarilo sa nacitat polynom na 2 mieste.\n"); pol[idx]=ch; }