Skip to main content

out.print vs output.println?

1 reply [Last post]
shahin912
Offline
Joined: 2011-09-30
Points: 0

Whats the difference between these?

out.print

output.println

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
OneJumpedUp
Offline
Joined: 2012-04-05
Points: 0

Hey
Yep this is a trick for new players

out.print( "Hello there " );
out.print( "Everybody" );

displays:
Hello there Everybody

without breaking the line, whereas:

out.println( "Hello there " );
out.println( "Everybody" );

displays:
Hello there
Everybody

breaking the line