What are the two ways of output using print()?
Answers
Answered by
9
One is- System.out.println() - This is used to print whatever is inside the body (brackets) and then shifts the control (cursor) to the next line so that the next set of statements get executed from the next line onwards.
Second is- System.out.print() - Here ln is missing as this prints the body then the cursor does not move...it stays at the very same place where it had ended executing before.
Hope this helped! PLZZZZZ mark as brainliest! :)))
Similar questions