Python Unit 4 QB
Python Unit 4 QB
Unit 4
S. Questions BL CO
PI
No 6 Marks CODE
1 How can you create List and how will you access a list? L1 CO4 1.1.1
3 Write any two basic operations of list with suitable snippets. L1 CO4 1.1.1
Give a brief note on any 5 basic functions of list with
4 L2 CO4 1.2.1
examples.
8 Write the difference between sort() and sorted() function. L3 CO4 1.3.1
Define tuple and write a statement to create a tuple ‘T1’ CO4
9 L4 1.4.1
containing first five even numbers.
S. Questions BL CO
PI
No 6 Marks CODE
S. Questions BL CO
PI
No 12 Marks CODE
Explain the list Slice notations in python with suitable
1 examples. L1 CO4 1.1.1
3 Write any four basic operations of list with suitable snippets. L1 CO4 1.1.1
Give a brief note on any 10 basic functions of list with
4 L2 CO4 1.2.1
examples.
What is nested list? Explain with a sample source code to
5 L4 CO4 1.4.1
extend nested list by adding the sublist..
Compare and contrast append() and extend() functions. How to
6 L3 CO4 1.3.1
clone or copy a list in python?
Explain briefly list comprehension and write a snippet to
7 L3 CO4 1.3.1
remove all odd numbers from the given list of numbers.
8 How to Count Occurrences of a List Item in Python. L3 CO4 1.3.1
Write a program to accept five numbers from the user and CO4
9 L4 1.4.1
store it in a tuple.
11 How do you add key value pairs to an existing dictionary? L2,3 C04 1.2.1
12 How is indexing of a dictionary different from that of a list or a L2,3 CO4 1.2.1
string? Explain in detail.
Briefly discuss the dictionary functions in detail. CO4
13 L3 1.3.1