Can a double value be cast to a byte?

Answers were Sorted based on User's Feedback



Can a double value be cast to a byte?..

Answer / ravikiran(aptech mumbai)

yes
double d=22.55;
byte b=(byte)d;

Is This Answer Correct ?    34 Yes 2 No

Can a double value be cast to a byte?..

Answer / niranjanravi

yes

Is This Answer Correct ?    24 Yes 2 No

Can a double value be cast to a byte?..

Answer / guest

yes

Is This Answer Correct ?    18 Yes 2 No

Post New Answer

More Core Java Interview Questions

What we have to do, when we don't want to implement all methods of an interface?

5 Answers  


What is set in java?

0 Answers  


Explain the selection sort algorithm and state its time complexity?

0 Answers   Flextronics,


i need to know the website that i can compile and run a java code in online.(while system doesn't contain any jdk and jre)

0 Answers  


Is there a sort function in java?

0 Answers  


What is the parse method in java?

0 Answers  


Why is it called boolean?

0 Answers  


Difference between Applet & Application?

6 Answers  


what is the main class of all the classes

5 Answers   Photon,


What is a line break?

0 Answers  


explain the concept of inheritance with an example?

9 Answers   Polaris,


Explain 5 io best practices?

0 Answers  


Categories