import matplotlib.pyplot as plt
import matplotlib.patches as mpatches
terms =["F03", "F04", "F05","F06", "F07", "F08", "F09", "F10", "F11", "F12", "F13","F14","F15","F16","F17","F18","F19","F20","F21","F22"]
total = [824, 642, 515, 472, 444, 482, 548, 605, 673, 833, 1033,1237,1383,1581,1733,1972,2170,2354,2663,3287]
xaxis = range(len(terms))
plt.figure(figsize=(12,8))
plt.xlabel("Term")
plt.ylabel("Total Enrollment Computer Science")
plt.xticks(xaxis, terms)
plt.bar(xaxis, total, width=0.5, color='blue')
for a,b in zip(xaxis, total):
plt.text(a, b+40, str(b), horizontalalignment='center', verticalalignment='center')
blue_patch = mpatches.Patch(color='blue', label='CS Enrollments')
plt.legend(handles=[blue_patch], loc='upper left')
plt.savefig('enroll.jpg', dpi=300, bbox_inches='tight')
plt.show()