Sagar Python
Sagar Python
0|Page
Write a program to read a list of elements.
Input an element from the user that has to be
inserted in the list. Also, input the position
at which it is to be inserted. Apply a built-in
1|Page
function to insert the element at the desired
position in the list.
2|Page
• Write an interactive program to create an
integer list of 8 integers and sort the
list in ascending order using bubble sort
method
3|Page
4|Page
Write a python program to shift each element of
a list to the right so that the last element
becomes the first element. For example, the
given list:
5|Page
Write a program to print all the elements of a
tuple in the reverse order.
6|Page
Write a program to input n numbers from the
user, store these numbers in a tuple and print
the maximum, minimum number along with the sum
and mean of all the elements from this tuple.
7|Page
Program to perform linear search on a tuple of
numbers.
8|Page
# OUTPUT:
9|Page
Write a program to input total number of
sections and stream name in 11th class and
display all information on the output screen.
10 | P a g e
# OUTPUT:
11 | P a g e
Write a program to enter names of employees
and their salaries as input and store them
in a dictionary.
12 | P a g e
# OUTPUT:
▪ s = 1+x2+x3+x4…+xn
13 | P a g e
Illustrating the working of break statement.
• S = (1)+(1+2)+(1+2+3)+……+(1+2+3+….+n)
14 | P a g e
# OUTPUT:
15 | P a g e
Q. Display the sum of all loan amounts whose interest
rate is greater than 10.
16 | P a g e
Q. Display the maximum interest from loans table.
# PRACTICAL IMPLEMENTATION:
17 | P a g e
# PRACTICAL IMPLEMENTATION:
18 | P a g e
Q. To display the details of those products whose name
ends with ‘wash’.
19 | P a g e
# PRACTICAL IMPLEMENTATION:
20 | P a g e
Q. To display the model_id, comp_id, cost from the
table model, compname and contactperson from company
table, with their corresponding comp_id.
# PRACTICAL IMPLEMENTATION:
21 | P a g e
Select * from bank_account natural join branch;
# PRACTICAL IMPLEMENTATION:
22 | P a g e
# PRACTICAL IMPLEMENTATION:
23 | P a g e
# PRACTICAL IMPLEMENTATION:
24 | P a g e
25 | P a g e