Help
Contact
For teachers and institutes
Search courses, problems, tests…
A
A
>_
StemPy Lab
Courses ▾
Problems ▾
Practice ▾
Mock Tests
Classes
Groups
Community ▾
A
A
Problems
/
Python Basics
/
Lists
Lists
Python Programming
+ Upload a Problem
More in Python Basics
Getting Started with Python
Variables and Data Types
Operators and Expressions
Input and Output
Strings
Conditionals: if, elif, else
Loops
Lists
Functions
Mini Projects
All Levels
Middle Stage (6–8)
High School (9–10)
High School (11–12)
Undergraduate
General
All
Easy
Medium
Hard
Sort
Mixed
Newest first
Oldest first
A to Z
15 problems
Type:
Any
Conceptual
Numerical
Python-Coded
1.
Here is a table of marks: one row for each student, and one column for each test.
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists
StemPy Lab
Medium
2.
What do a and b show at the end? Say it before you run it.
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists
StemPy Lab
Medium
3.
The list is marks = [45, 78, 90, 62, 38, 85, 71].
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists, Loops
StemPy Lab
Easy
4.
Find the position
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists
StemPy Lab
Easy
5.
The list is days = ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"].
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists
StemPy Lab
Easy
6.
From the list [3, 1, 3, 2, 1], make a new list that has each value only once, in the order of the…
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists, Loops
StemPy Lab
Hard
7.
Change cat into bat (a) with a list of letters and (b) with a string. Which one is easier?
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists
StemPy Lab
Medium
8.
a = [1, 2, 3] and then b = a and b.append(4). What is a? How do you make a separate copy?
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists
StemPy Lab
Hard
9.
Build the list of the squares of 1 to 6: [1, 4, 9, 16, 25, 36].
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists, Loops
StemPy Lab
Medium
10.
A mark of 60 or more is a pass. How many of [72, 85, 64, 90, 58] passed?
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists, Loops
StemPy Lab
Medium
11.
Find the highest mark, the lowest mark and the difference between them for [72, 85, 64, 90, 58].
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists, Loops
StemPy Lab
Easy
12.
Find the total and the average of the marks 72, 85, 64, 90 and 58.
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists, Loops
StemPy Lab
Medium
13.
Put the marks [72, 85, 64, 90, 58] in order, first with the smallest first, then with the biggest…
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists
StemPy Lab
Easy
14.
The list is ["milk", "rice", "tea"]. Add eggs at the end, remove milk, and put bread at the very…
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists
StemPy Lab
Easy
15.
For fruits = ["apple", "mango", "kiwi", "plum"], find fruits[0], fruits[-1], fruits[1:3] and…
Middle Stage (6–8), High School (9–10), High School (11–12), Undergraduate, General · Lists
StemPy Lab
Easy