G
This commit is contained in:
parent
a9eb7f112e
commit
58628dc497
@ -2,30 +2,6 @@
|
|||||||
|
|
||||||
#define FIELD_SIZE 52
|
#define FIELD_SIZE 52
|
||||||
|
|
||||||
int main(){
|
|
||||||
int field[FIELD_SIZE] = {0};
|
|
||||||
int count = 0;
|
|
||||||
int max_num = 0;
|
|
||||||
int input;
|
|
||||||
|
|
||||||
while (count < FIELD_SIZE) {
|
|
||||||
if (scanf("%d", &input) != 1) {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
if (input < 0) {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
field[count] = input;
|
|
||||||
count++;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (int i = 0; i < count; i++) {
|
|
||||||
printf("Sutaziaci č. %d vypil %d pohárov.\n", i + 1, field[i]);
|
|
||||||
}
|
|
||||||
printf("Výherca je súťažiaci %d ktorý vypil %d pohárov.\n",i+1,field[i]);#include<stdio.h>
|
|
||||||
|
|
||||||
#define FIELD_SIZE 52
|
|
||||||
|
|
||||||
int main(){
|
int main(){
|
||||||
int field[FIELD_SIZE] = {0};
|
int field[FIELD_SIZE] = {0};
|
||||||
int count = 0;
|
int count = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user