Assignment-1(Unit-1) Python Programming
PYTHON PROGRAMING (BCC 302)
Due Date 15-09-2025
Note:
1. Mention your Name, Roll-Number, Branch, Section, and subject code.
2. Only hand-written answers will be accepted.
3. Assignment will be submitted on either stick file in A4 pages or make it in a notebook
4. Students have to submit 10 question only ( Q.1-10) even roll number , ( Q. 11-20) odd roll number
[Link] to check whether a given number is positive, negative, or zero using if-else.
2. Give difference between = = and is operator in python?
[Link] to take two numbers and display their sum, difference, product, quotient & remainder
4. Explain Boolean data type in Python with examples.
5. Which command is used to check the installed Python version?
6. Demonstrate the difference between / and // operators with the help of program
7. Provide a definition of Python and explain its key strengths. Highlight its significant features and
discuss why it is considered more beginner-friendly compared to languages like C or Java.
[Link] we use else with a for loop? if so when it is executed?
[Link] difference between List and Tuple in Python
10. Write short notes on:
i) Data types ii) Importance of Python Blocks
11. Explain the concept of set in Python and its Characteristics .How elements are
added and removed in set?
12 Consider the following Python expression and predict the output using operator
. precedence and associatively:
a. (10 + 2) * 3 ** 2 // 4 % 5 + 7
b. 100 // 3 ** 2 % 7 + 2 * 5 – 8
c. 4 ** 2 ** 3 // 5 * 2
d. (15 - 3) * 2 ** 3 // 5 + 9 % 4
13. Who developed Python programming language? Which version of Python is currently the latest stable release?
14 Explain the purpose of Break and Continue statement in loops with Examples?
15) Define a list in python? Write a program to remove duplicates from the list and print the
resulting list?
16) Explain string and tuple data Type in Python with suitable example?
17
) WAP how to assign a single value to a Tuple.
18) Define Membership and Identity operators?
Given
a=3
b=3
distinguish between ( a is b) and (a= = b) .
19
) Design a simple calculator in python that supports addition, subtraction, multiplication and
division.
20) Create a list of 10 numbers. Perform the following operations: append, insert at 3rd
position, remove 5th element, sort ascending, and slice last 3 elements.