Page 24 - IPP-12-2024
P. 24
Ans. import matplotlib.pyplot as plt
blood_group=["A+", "A+", "AB-", "O+", "B+", "O-", "A+", "AB+", "O+", "A+"]
plt.title("STUDENTS' BLOOD GROUP")
plt.xlabel("Blood Groups")
plt.ylabel("Number of Students")
plt.hist(blood_group, bins=20)
plt.show()
plt.savefig("studentsbloodgroup.jpg")
OR
import matplotlib.pyplot as plt
height= [21.5, 23, 24.2, 25.1, 25.9, 26.6, 27.2, 27.8, 28.3, 28.9, 29.3,
29.8]
month= [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]
plt.title("WHO growth standards for boys")
plt.xlabel("Age (months)")
plt.ylabel("Height (inches)")
plt.plot(month, height, marker="o")
plt.grid(True)
plt.show()
plt.savefig("growthstandard.jpg")
MODEL TEST PAPER 11