What happens when you add a double value to a string?



What happens when you add a double value to a string?..

Answer / Ankur Parashari

If you concatenate a double value with a String using the '+' operator, Java will first convert the double to a String and then concatenate it.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

Which is easier netbeans or eclipse?

1 Answers  


when a servlet sends request for first time it uses the follwing methods a)init b)doget() c)dopost() d)service

4 Answers   Accenture,


1.) if we use "private" in place of "public" in public static void main()... 2.) if we use "int" in place of "void".... 3.) can we ommit "static" keyword from that statement.... 4.) also can we give the command line arguments type as int type or float,etc.(.i.e (string args[]))

1 Answers  


Is string a keyword in java?

1 Answers  


What is the size of int in 64-bit jvm?

1 Answers  


How would you convert bytes to string?

1 Answers  


What exactly is java?

1 Answers  


What collections you have worked on? Internal working of Hashmap?

1 Answers   Bravura Solutions,


Why is multiple inheritance not supported in java?

1 Answers  


Can list be final in java?

1 Answers  


How will you measure that int takes up only 32 bits in memory?

2 Answers   Rolta,


How do you identify if jvm is 32-bit or 64-bit from java program?

1 Answers  


Categories