Data type conversion

Data type conversion: Conversion of one data type into the other data type. Two kind of conversion that is,

A) Implicit Conversion: This is automatically taken care by complier in the situation of lower range to higher range example: int x, char c=’A’ then x=c is valid that is, character value in c is automatically transformed to integer.

B) Explicit Conversion: This is user-defined which forces an expression to be of specific kind. Example: double x1, x2 and int res then res = int(x1 + x2)

   Related Questions in Programming Languages

©TutorsGlobe All rights reserved 2022-2023.