0% found this document useful (0 votes)
26 views3 pages

Art Integration AI

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views3 pages

Art Integration AI

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Art

Inte
Subject: Artificial Intelligence grat
Topic: Create a Python program to display the population of Assam from 1901 to 2021
using bar graph.
Learning Outcome:
Students will be able to understand and can create bar graphs with different values
using python matplotlib.
Instructions to be followed:
 Use only A4 sheets
 Draw 4 side boarders
 Write only 1 side of the A4 sheet
 Write the output of the program in a separate A4 sheet
 Do not take any printouts, all the programs should be handwritten only.

Rubrics Presentation Content Program Output


Python Program:
import matplotlib.pyplot as plt
import numpy as np
years=[1901,1911,1921,1931,1941,1951,1961,1971,19
81,1991,2001,2011]
pop=[3289680,3848617,4636980,5560371,6694790,80
28856,10837329,14625152,18041248,22414322,26655
528,31205576]
plt.title('Assam population bar graph')
plt.xticks(np.arange(1901, 2021, step=10),
labels=years)
plt.xlabel('Years')
plt.ylabel('population')
colors=['red','black','blue','cyan','yellow','red','black','bl
ue','cyan','yellow','green']
plt.bar(years,pop,color=colors,width=5)
plt.show()
Output:

You might also like