Floating-point numbers are double by default in Java and C++. So, Java or C++ compiler considers 9.99 as double. To declare it as a float value, you need to add 'f' or 'F' as a suffix, like '9.99f'.