Bad input fix

This commit is contained in:
Anton Dolozin 2025-10-06 16:20:28 +02:00
parent 2ff0fd0ddf
commit b69493904e

View File

@ -68,7 +68,7 @@ void process_operations(struct stack* stack) {
char *endptr;
float val = strtof(line, &endptr);
if (endptr == line) {
printf("no input\n");
printf("bad input\n");
return;
}
push_stack(stack, val);