0% found this document useful (0 votes)
5 views

Programming in Python - - Unit 6 - Week 6 (Contents)_ Introduction to list_

The document outlines the contents and assessments for a Programming in Python course, specifically focusing on lists in Unit 6. It includes various coding questions and their expected outputs, along with scores for completed assignments. The document also provides links to additional resources and course materials.

Uploaded by

rvseceprint
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

Programming in Python - - Unit 6 - Week 6 (Contents)_ Introduction to list_

The document outlines the contents and assessments for a Programming in Python course, specifically focusing on lists in Unit 6. It includes various coding questions and their expected outputs, along with scores for completed assignments. The document also provides links to additional resources and course materials.

Uploaded by

rvseceprint
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

4/23/24, 2:14 AM Programming in Python - - Unit 6 - Week 6 (Contents): Introduction to list.

(https://swayam.gov.in) (https://swayam.gov.in/nc_details/CEC)

[email protected]

CEC (https://swayam.gov.in/explorer?ncCode=CEC) » Programming in Python (course)

Course Assessment-6-2024
outline The due date for submitting this assignment has passed.
Due on 2024-03-24, 23:59 IST.
Week 1 Score: 10/10=100%
(Contents) :
Planning the
Computer Assignment submitted on 2024-03-21, 15:18 IST
Program () 1) What will be the output of the following code? 1 point
print(list("Assam"))
Week 2
(Contents): ['A', 's', 's', 'a', 'm']
Techniques ['Assam']
of Problem
[A, s, s, a, m]
Solving ()
['A, s, s, a, m']
Week 3 Yes, the answer is correct.
(Contents): Score: 1
Introduction Accepted Answers:
to Python () ['A', 's', 's', 'a', 'm']

Week 4 2) What will be the output of the following code? 1 point


(Contents): list1 = ['abhi', 'zee', 'PYlan']
Conditional print (max(list1))
Statements
and Looping abhi
() zee
PYlan
Week 5
Error
(Contents):
String Yes, the answer is correct.
Manipulation Score: 1
() Accepted Answers:
zee

https://onlinecourses.swayam2.ac.in/cec24_cs01/unit?unit=31&assessment=97 1/4
4/23/24, 2:14 AM Programming in Python - - Unit 6 - Week 6 (Contents): Introduction to list.

3) What will be the output of the following code? 1 point


Week 6
list = [1, 2, 3, 4]
(Contents):
list.append([5,6,7,8])
Introduction
print(len(list))
to list. ()

8
Lecture 1:
Introduction to 4
list. (unit? 5
unit=31&lesso
2
n=32)
Yes, the answer is correct.
Lecture 2: Score: 1
Accessing list
Accepted Answers:
and list
5
Operations.
(unit?
unit=31&lesso 4) What will be the output of the following code? 1 point
n=33) a=[1]
b=a.append(2)
Lecture 3:
print(b)
Working with
lists. (unit? [1, 2]
unit=31&lesso
n=34)
None

Yes, the answer is correct.


Lecture
Score: 1
Materials
Accepted Answers:
(unit?
None
unit=31&lesso
n=35)
5) What will be the output of the following code? 1 point
Quiz: a = [1, 2, 3]
Assessment- b=a
6-2024
b[1] = 4
(assessment?
print(a)
name=97)

[1, 2, 3]
Week 7
(Content): [1, 2, 4]
Introduction [1, 4, 3]
to tuples. () [2, 4, 3]

Week 8 Yes, the answer is correct.


Score: 1
(Contents):
Accepted Answers:
Introduction
[1, 4, 3]
to
dictionaries
6) What will be the output of the following code? 1 point
()
list1 = [25,48,56,48,90,23]
print(list1.count(48))
Week 9
(Contents):
0
Python
Functions () 1
2
Week 10 3
(Contents) :
Y h i

https://onlinecourses.swayam2.ac.in/cec24_cs01/unit?unit=31&assessment=97 2/4
4/23/24, 2:14 AM Programming in Python - - Unit 6 - Week 6 (Contents): Introduction to list.

Python Yes, the answer is correct.


Modules () Score: 1
Accepted Answers:
2
Week 11
(Contents): 7) What will be the output of the following code? 1 point
Input-Output numbers = [1, 2, 3, 4, 5]
() print(numbers[-2])

Week 12 2
(Contents): -2
Exception
3
Handling ()
4

Yes, the answer is correct.


Score: 1
Accepted Answers:
4

8) What will be the output of the following code? 1 point


list = [1, 2]
list.extend([5,6])
print(list)

[1, 2, 5, 6]
[1, 2]
[5, 6]
No output

Yes, the answer is correct.


Score: 1
Accepted Answers:
[1, 2, 5, 6]

9) What is the correct way to create an empty list in Python? 1 point

list = {}

list = []

list = ()

list = [None]

Yes, the answer is correct.


Score: 1
Accepted Answers:
list = []

10) What does slicing a list in Python return? 1 point

https://onlinecourses.swayam2.ac.in/cec24_cs01/unit?unit=31&assessment=97 3/4
4/23/24, 2:14 AM Programming in Python - - Unit 6 - Week 6 (Contents): Introduction to list.

A new list containing the sliced elements

The original list with sliced elements removed

A tuple containing the sliced elements

An error because lists in Python cannot be sliced

Yes, the answer is correct.


Score: 1
Accepted Answers:
A new list containing the sliced elements

You were allowed to submit this assignment only once.

https://onlinecourses.swayam2.ac.in/cec24_cs01/unit?unit=31&assessment=97 4/4

You might also like