[Go to site: main page, start]

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

QB-Module 3 Python (Final)

The document outlines a series of questions related to Python programming, covering definitions of strings, tuples, lists, dictionaries, and NumPy, as well as programming tasks that involve counting vowels, tuple assignment, list operations, and file handling. It also includes theoretical questions comparing lists and tuples, explaining aliasing, and justifying the use of NumPy arrays. The questions are categorized into two sections: two-mark questions and four-mark questions.

Uploaded by

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

QB-Module 3 Python (Final)

The document outlines a series of questions related to Python programming, covering definitions of strings, tuples, lists, dictionaries, and NumPy, as well as programming tasks that involve counting vowels, tuple assignment, list operations, and file handling. It also includes theoretical questions comparing lists and tuples, explaining aliasing, and justifying the use of NumPy arrays. The questions are categorized into two sections: two-mark questions and four-mark questions.

Uploaded by

sairan23
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Module-III

Two Marks:

1. Define a string in Python.


2. Why are strings immutable?
3. What is a tuple?
4. What is tuple assignment?
5. Define a list.
6. What is aliasing?
7. What is a dictionary?
8. Define NumPy.
9. What is broadcasting in NumPy?
10. What is a module?
11. What is namespace?
12. Define class and object.

Four Mark Questions:

PROGRAM QUESTIONS

13. Write a Python program to count the number of vowels in a given string.
14. Write a Python program to demonstrate tuple assignment and returning multiple
values from a function.
15. Write a Python program to create a list and perform any four list operations.
16. Write a Python program to create a dictionary and perform insertion, deletion, and
searching of elements.
17. Write a Python program to read a file line by line and display its contents.
18. Write a NumPy program to demonstrate array slicing and masking.
19. Write a Python program to define a class, create an object, and access its attributes
and methods.

THEORY / ANALYTICAL QUESTIONS

20. Compare lists and tuples with suitable examples.


21. Explain aliasing and cloning in lists with examples.
22. Justify the use of NumPy arrays over Python lists.

You might also like