0

What is type casting?

7th Feb 2020, 11:38 AM
Aayush Sadashiv Joshi
Aayush Sadashiv Joshi - avatar
4 Answers
+ 5
int -> float -> double int can be converted to float and float can be converted to double without explicit conversion. This is called type conversion. Type casting is the explicit conversion of one data type to the other. Edit: ~ swim ~ I got confused between type casting and type conversion. Apparently one applies for the implicit action and the other for the explicit action. I have slightly modified my answer statement.
7th Feb 2020, 11:42 AM
Avinesh
Avinesh - avatar
0
Thank you
7th Feb 2020, 11:42 AM
Aayush Sadashiv Joshi
Aayush Sadashiv Joshi - avatar