Python Program to Print Output Without a Newline

bookmark

# print each statement on a new line
print("Python")
print("is easy to learn.")

# new line
print()

# print both the statements on a single line
print("Python", end=" ")
print("is easy to learn.")

 

Output

Python
is easy to learn.

Python is easy to learn.