Basic Java Interview Question and Answers
33. | How to create an immutable class? |
---|---|
|
|
34. | What is the difference between implicit and explicit type casting? |
---|---|
An explicit conversion is where you use syntax to tell the program to do a conversion whereas in case of implicit type casting you need not provide the data type. | |
35. | What is downcasting? |
---|---|
Downcasting means creating from a general to a more specific type. | |
36. | What are the different types of casting? |
---|---|
|
|