♦ Float to Int in C++
♣ Example1: Float to Int in C++
Float is a Data Type which can store a real number of certain range.Int is a Data Type which can store integer values of certain range.
Float to Int conversion will chop down the decimal-part(if exists) of the number to give out integer.
In this example, multiple Float to Int conversions are illustrated.
Example
Input:
Output: