From e09fdc69fb18179fec686951dab3406444b19fe6 Mon Sep 17 00:00:00 2001 From: Saurav Kumar <104313290+Souravhypertext@users.noreply.github.com> Date: Sun, 30 Oct 2022 11:03:15 +0530 Subject: [PATCH] Add files via upload --- python.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 python.py diff --git a/python.py b/python.py new file mode 100644 index 0000000..4e6b78a --- /dev/null +++ b/python.py @@ -0,0 +1,21 @@ +# importing the required module +import matplotlib.pyplot as plt + +# x axis values +x = [1,2,3] +# corresponding y axis values +y = [2,4,1] + +# plotting the points +plt.plot(x, y) + +# naming the x axis +plt.xlabel('x - axis') +# naming the y axis +plt.ylabel('y - axis') + +# giving a title to my graph +plt.title('My first graph!') + +# function to show the plot +plt.show()