the difference between write and writeln

A

alu

Jason Cook said:
What is the difference?

The write method is the same as the writeln method, except the write method
does not append a newline character to the end of the output.
 
C

Christophe Vanfleteren

Jason said:
What is the difference?

Please put your question in the body, and not in the subject.

One just writes to the outputstream, the other writes a line (meaning that
the next write/writeln call will be written on a new line).
 
T

Thomas 'PointedEars' Lahn

Jason said:
What is the difference?

writeln = "write line"

Some JavaScript engines append newline when using writeln(...),
but not when using write(...). I recommend to use write("...\n")
if newline is required.


PointedEars
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top