C validating input char

If you want the second, which I think you do, you will have to deal with the possibility that you may have several "Enter correct letter" statements on the screen if you have a dumb user.

I am trying to look through my textbooks but can't see anything about that. I can't believe something that simple gave me such a headache, you opened my eyes a lot, however you did not add the space between the " and % in the scanf statement, so when I got to letter input the output was: Enter A (for AM) or P (for PM): Enter correct value: A But with the space between the " and % in my scanf statement it solved the problem of "enter correct value" popping up before I even got to enter either A or P or an incorrect value.

And then when I enter either A or P it finally recognizes the letter and then ends the program.

I am so lost as to why this check_letter() function is doing this to me.

ncurses) that lets you do fancy stuff like rewrite the same line.

But those are complicated and too much effort for your project I think.