Use app×
Join Bloom Tuition
One on One Online Tuition
JEE MAIN 2025 Foundation Course
NEET 2025 Foundation Course
CLASS 12 FOUNDATION COURSE
CLASS 10 FOUNDATION COURSE
CLASS 9 FOUNDATION COURSE
CLASS 8 FOUNDATION COURSE
0 votes
83 views
in Information Technology by (54.6k points)
closed by

Consider the following program and answer the questions from a to e

import matplotlib.pyplot as pl

a. l1=[1,4,6,8]

b. l2=[2,8,9,10]

c. l3=[1,5,7,9]

d. l4=[5,2,6,1]

________________________#Line 1

pl.plot(l3,l4,label="Australia")

pl.legend(loc="upper left")

________________________#Line 2

pl.ylabel("Goals")

_______________________#Line 3

________________________#Line 4

________________________# Line 5

a. What will be the line to be written in #Line 1 to plot a line chart:

i. pl.plt(l1,l2,label="India")

ii. pl.show(l1,l2,label="India")

iii. pl.plot(l1,l2,label="India")

iv. pl.line(l1,l2,label="India")

b. What will be the line to be written in #Line 2 to set label on x axis:

i. pl.xlabels("Time")

ii. pl.labelx("Time")

iii. pl.xlabel("Time")

iv. pl.xaxislabel("Time")

c. What will be the line to be written in #Line 3 to set title of the chart:

i. pl.titles("Chart of Score in game")

ii. pl.settitle("Chart of Score in game")

iii. chart.title("Chart of Score in game")

iv. pl.title("Chart of Score in game")

d. What will be the line to be written in #Line 4 to show the chart made:

i. pl.showchart()

ii. pl.chartshow()

iii. pl.show()

iv. pl.fullchartshow()

e. What will be the line to be written in #Line 5 to save the chart made:

i. pl.savefigure("abc.jpg")

ii. pl.savechart("abc.jpg")

iii. pl.chartsavefig("abc.jpg")

iv. pl.savefig("abc.jpg")

1 Answer

+1 vote
by (55.0k points)
selected by
 
Best answer

a. iii. pl.plot(l1,l2,label="India")

b. iii. pl.xlabel("Time")

c. iv. pl.title("Chart of Score in game")

d. iii. pl.show()

e. iv. pl.savefig("abc.jpg")

Welcome to Sarthaks eConnect: A unique platform where students can interact with teachers/experts/students to get solutions to their queries. Students (upto class 10+2) preparing for All Government Exams, CBSE Board Exam, ICSE Board Exam, State Board Exam, JEE (Mains+Advance) and NEET can ask questions from any subject and get quick answers by subject teachers/ experts/mentors/students.

Categories

...