?
This commit is contained in:
parent
b3e37838ff
commit
4a873fe7e4
@ -34,10 +34,6 @@ int main() {
|
|||||||
char name[SIZE];
|
char name[SIZE];
|
||||||
int velkost_zoznamu = 0; //pocet studentov
|
int velkost_zoznamu = 0; //pocet studentov
|
||||||
|
|
||||||
if ((fgets (vstup, SIZE, stdin) != NULL) && (sscanf(vstup, "%d %[^\n]", &hlasy, name) != 2)) {
|
|
||||||
printf("Nepodarilo sa nacitat nic\n");
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
while (fgets (vstup, SIZE, stdin) != NULL) {
|
while (fgets (vstup, SIZE, stdin) != NULL) {
|
||||||
//citat input, kontrola ci existuje, pridat hlasy existujucemu zaznamu
|
//citat input, kontrola ci existuje, pridat hlasy existujucemu zaznamu
|
||||||
if (sscanf(vstup, "%d %[^\n]", &hlasy, name) != 2) {
|
if (sscanf(vstup, "%d %[^\n]", &hlasy, name) != 2) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user