C++ · Input, output and math

When input goes wrong

Users mistype. A program that trusts every read can print a confident wrong answer, so it needs to know when a read failed.