What happens when you assigned a 'double' value to
a 'String'?

Answer Posted / paras bist

compilation fails ,
even for
double d=10.5;
String f=(String)(10.5);

"Cannot cast from double to String"

Is This Answer Correct ?    6 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can you set the applet size?

565


What is indexof in java?

506


What do you mean by compiler?

569


Difference between notify() method and notifyall() method in java?

540


Can you give few examples of final classes defined in java api?

550






How many ways can we create the string object?

524


What are the methods of object class ?

554


What is array length in java?

519


What is this () in java?

566


What is a file pointer?

504


How to find the given number is a prime number or not by getting input from the user

540


How do I get the | symbol on my keyboard?

585


Why static functions are used?

559


What does split function do in java?

528


4.1 Supply contracts (in the form of comments specifying pre- and post conditions) for the enqueue() method of the LinkedQueue class given in the Appendix. (2) 4.2 Let Thing be a class which is capable of cloning objects, and consider the code fragment: Thing thing1 = new Thing(); //(1) Thing thing2 = thing1; //(2) Thing thing3 = (Thing) thing1.clone(); //(3) Explain how the objects thing2 and thing3 differ from each other after execution of the statements. (

1402