In Java 3 = 12..

In Java 3 = 12..

In Java, the output:

     System.out.println(1 + 2 + " = " + 1 + 2);
=> 3 = 12

Because Java starts treating everything as a String once it has found a string in System.out statement. Interesting, huh...

No comments:

Post a Comment

Grab The Button...

Grab the above button and add to your blog or website to get easy access to Virtual Species. Simply click the textbox, copy the code and paste where you want to see the button. That's it!

About Author...

My photo

Technophile and believer of 'Be the Change to Change the World' _(Try to ♲)