usaa21/cv1/program.c
Damián Korpesio 40cf04856b skuska inputu
2021-10-06 18:43:24 +02:00

54 lines
849 B
C

#include <stdio.h>
#include <string.h>
#define LINESIZE 100
struct Pizza {
float prize;
char name[LINESIZE];
};
//int matches(heap, needle){
// return 0;
//}
//char hacker_script(char c){
// if (c == '5'){
// r == 'S';
// }
// return r;
//}
int main (){
size_t velkost = 0;
char line[LINESIZE];
memset(line, 0, LINESIZE);
//char search_string[LINESIZE] = "Ostiepkova";
while(1){
char *r = fgets(line, LINESIZE, stdin);
velkost = strlen(line);
if (r == NULL || velkost == 1){
printf("%s", line);
break;
}
struct Pizza pizza;
memset(line, 0,sizeof(struct Pizza));
strcpy(pizza.name, line);
//if (matches(search_string. line)){
// printf("%s", pizza->name);
//}
// strcpy(pizz->name, line);
// if (matches(search_string, line)){
// printf("%s", pizza->name)
// }
//
}
return 0;
}