Home »
MCQs »
Java MCQs
What is type casting in Java?
17. What is type casting in Java?
- It is converting type of a variable from one type to another
- Casting variable to the class
- Creating a new variable
- All of these
Answer: A) It is converting type of a variable from one type to another
Explanation:
Type casting is when you assign a value of one primitive data type to another type.