♦ Int to Float in C++
♣ Example2: Int to Float in C++
Int is a Data Type which can store integer values of certain range.Float is a Data Type which can store a real number of certain range.
Int to Float conversion will add an extra decimal option for the variable which can be used potentially in future for float type operations.
In this example, multiple Int to Float conversions are illustrated.
Example
Input:
Output: