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

Python Computer Abcd

Uploaded by

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

Python Computer Abcd

Uploaded by

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

Python Theory

Assignment1

Assignment Date: 22.10.24 and submission date: 25.10.24

1. State and explain any six features of python.

2. State any six applications of python.

3. State any six reasons, why you must consider writing software applications in Python.

4. Explain input command in python with suitable example.

5. Explain print command in python with suitable example.

6. State which of the following python statements are valid and invalid.

a. print("ksk", + "123")

b. print("ksk" '+' "123")

c. print("ksk", '+', "123")

d. print('ABC is a "technological" University')

e. print(2 + '3')

f. print('2' * 3)

7. What will be the output of following print statements?

a. print('abc' * 2)

b. print(3+4j + 2+1j)

c. print(3*2 // 4)

8. What are the types of following variables?

a. a = 55

b. b = ‘3 + 4j’

c. c = “1DBATU”

d. d = 5 + 2j

e. e = a

f. f = b+c

9. Explain any six arithmetic operators of python with suitable examples of each.

10. Explain any six assignment operators of python with suitable examples of each.

11. Explain all comparison operators of python with suitable examples of each.

12. Explain “and, or, not” operators of python with suitable examples of each.

13. Explain all bitwise operators of python with suitable examples of each.
14. Explain while loop with suitable example?

15. Differentiate between List, Tuple & Set with suitable examples of each.

16. Explain any three collection data types of Python with suitable examples of each.

17. Explain append() and copy() methods of list with suitable examples of each.

18. Explain count() and index() methods of list with suitable examples of each.

19. Explain insert() and remove() methods of list with suitable examples of each.

20. Explain reverse() and remove() methods of list with suitable examples of each.

21. Explain clear() and extend() methods of list with suitable examples of each.

22. Explain pop() and sort() methods of list with suitable examples of each.

23. What will be the output of following python statements?

a. print(23 // 5)

b. print(2 << 2)

c. print(2 >> 0)

d. print(2 ^ 2)

e. print(2 != 2)

f. print(2 < 0)

You might also like