You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When asked for the name of a fixture, it gathers straight from stdin, bun when doing this it only accepts 1 word. Then it moves on the the next line of code. Next time the program tries takin data from stdin, it won't wait for user input since there still is leftover from last time. This causes the problem of: it asks for a name, I the user puts in a name with a space, the program asks for the quantity of fixtures, spillover from user input causes quantity to be taken as part of user inputted name, which not only prevents there user from inputting a quantity, it also tries to store a string into an int var.
This could be solved either by using getline(). Or by flushing stdin after accepting one input, it is generally easier to go for the second option, but I still have not figured out how (I have tried)
No description provided.
The text was updated successfully, but these errors were encountered: