Computer Science - Class 12
Solutions to CBSE Sample Paper - Computer Science Class 12

Write the Python statement for each of the following tasks using BUILTIN functions/methods only:

(i) To remove the last element from the list L2 and store it in a variable x.

Answer:

Answer by student

The Python statement to  remove the last element from the list L2 and store it in a variable x is:

x = L2.pop() 

Detailed answer by teachoo

The rest of the post is locked. Join Teachoo Black to see the full post.

Go Ad-free
Davneet Singh's photo - Co-founder, Teachoo

Made by

Davneet Singh

Davneet Singh has done his B.Tech from Indian Institute of Technology, Kanpur. He has been teaching from the past 14 years. He provides courses for Maths, Science and Computer Science at Teachoo