0% found this document useful (0 votes)
6 views1 page

Assignment 02 (List, Tuple)

The document provides an overview of Lists and Tuples in Python, including definitions and differences between the two. It contains various Python programming tasks related to lists, such as finding the largest element, interchanging elements, counting occurrences, and creating new lists based on specific conditions. Additionally, it discusses methods like append() and extend() for manipulating lists.

Uploaded by

Richa Chaudhary
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views1 page

Assignment 02 (List, Tuple)

The document provides an overview of Lists and Tuples in Python, including definitions and differences between the two. It contains various Python programming tasks related to lists, such as finding the largest element, interchanging elements, counting occurrences, and creating new lists based on specific conditions. Additionally, it discusses methods like append() and extend() for manipulating lists.

Uploaded by

Richa Chaudhary
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 1

Topic - List, Tuple

1. What is a List?
2. What is a Tuple?
3. What is the difference between List and Tuple?
4. Python Program to find the largest element in the list
5. Python program to interchange first and last elements in a list. 6.
Python program to swap two elements in a list
7. Python program to Reverse a List
8. Python program to count occurrences of an element in a list 9.
Python program to find the sum of elements in a list
10. Python program to Multiply all numbers in the list
11. What are the ways to find the length of a list
12. Python program to find the smallest and largest number in a list (Without min-
max function)
13. Python Program to find the area of a circle
14. Take inputs from the user to make a list. Again take one input from the user
and search it in the list and delete that element, if found. Iterate over a list
using for loop.
15. You are given a list of integer elements. Make a new list that will store a square
of elements of the previous list. (With and without list comprehension) i.
Input_list = [2,5,6,12]

ii. Output_list = [4,25,36,144]


16. WAP to create two lists, one containing all even numbers and the other
containing all odd numbers between 0 to 151
17. Python program to Count Even and Odd numbers in a List 18. WAP to make
new lists, containing only numbers which are divisible by 4, 6, 8, 10, 3, 5, 7, and 9
in separate lists for range(0,151)
19. From a list containing ints, strings, and floats, make three lists to store them
separately.
20. What’s The Difference Between The Python append() and extend() Methods?
21. Write a Python program to append a list to the second list
22. Write a Python program to find the third-largest number in a list 23.
Write a Python program to get the frequency of the elements in a list. 24.

You might also like