Print without newline \n in Xcode

Print is a global function in swift 4.This function prints the output in Xcode console pane followed by a linebreak n.

The syntax for print function is:

print(_:separator:terminator:)

Separator and terminator have default values.

By adding an empty string “” value for terminator, linebreak will not be printed in Xcode console pane.

Advertisements

Leave a Reply