Dremendo Tag Line

Print string with tabs in Python

print() - Question 2

In this question, we will see how to print string with tabs in python programming using the print() function. To know more about print() function click on the print() function lesson.

Q2) Write a program in python to print the name of 3 animals in a single line on the screen using tabs between the names.

Program

print('Tiger\tElephant\tLion')

Output

Tiger   Elephant        Lion
video-poster