Floating point literals are used to represent signed real numbers. The following suffixes can be used to specify type of a literal:
In order to use these suffixes, the literal must be a floating point literal. For example,
3f is an error, since
3 is an integer literal, while
3.0f are correct. For
long double, the recommendation is to always use capital
L for the sake of readability.