I am learning C++ by reading Stroustrup\'s \"Principles and Practice Using C++\".
In the section about pre- and post-conditions there is the following example of functio
What comes to my mind is a signed overflow. It is undefined behavior but might yield a negative value. Try std::numeric_limits::max() and 2.
std::numeric_limits::max()
2