Simple Way to display Tabular data in Python

Here below is a simple program to display data (list or list of dictionaries) in a tabular format using the “tabulate” package.

This is the required output:


If you don’t have the “tabulate” package installed, you can install it using:

pip install tabulate

The Program:

Following is the program code:

Sample Run:

Following is a sample run of the above program:



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s