diff --git a/a1/program.c b/a1/program.c index 07f6041..6a1319f 100644 --- a/a1/program.c +++ b/a1/program.c @@ -4,19 +4,19 @@ long double power(long double x, int y); int main() { - double x; - double coef[100]; + float x; + float coef[100]; int coefCount = 0; int retVal; long double result = 0; - if ((retVal = scanf("%lf", &x)) <= 0 || retVal == EOF) { + if ((retVal = scanf("%f", &x)) <= 0 || retVal == EOF) { printf("%s\n", "Chyba: Nespravny vstup"); return 0; } for (int i=0; i<100; i++) { - retVal = scanf("%lf", &coef[coefCount]); + retVal = scanf("%f", &coef[coefCount]); if (coef[i] == 0) { break;