PRACTICAL RECORD-CLASS-11 (2)
PRACTICAL RECORD-CLASS-11 (2)
PRACTICAL RECORD-CLASS-11 (2)
CLASS-XI
PRACTICAL RECORD(2022-23)
1. To find average and grade for given marks.
Output:
Output:
enter the side of square:5
Area of square is: 25.0
# Calcualtion
simple_interest = (principal*time*rate)/100
compound_interest = principal * ( (1+rate/100)**time - 1)
# Displaying result
print('Simple interest is:' , simple_interest)
print('Compound interest is:' ,compound_interest)
Output:
Enter amount: 50000
Enter time: 2
Enter rate: 2
Simple interest is: 2000.0
Compound interest is: 2019.9999999999995
5. To calculate profit-loss for given Cost and Sell Price.
if cp==sp:
else:
if sp>cp:
print("Profit of ",sp-cp)
else:
print("Loss of ",cp-sp)
Output:
Profit of 100.0
6. To calculate EMI for Amount, Period and Interest.
si=p*t*r/100
tot=p+si
emi=tot/(12*t)
print('EMI AMOUNT:',emi)
Output:
GST_amount = np - p
print("GST = ",round(GST_percent),'%')
Output:
GST = 20 %
8. To calculate Income Tax
If annual income is less than or equivalent to Rs. 2,50,000, you will pay no tax.
If annual income is less than or equal to Rs. 5,00,000, your tax will be 5% of your total
income over Rs. 2,50,000.
If annual income is less than or equal to Rs. 7,50,000, your tax rate will be 10% of your
total income beyond Rs. 5,00,000, with an additional cost of Rs. 12,500.
If annual income is less than or equivalent to Rs. 10,00,000, your tax rate will be 15% of
your total income over Rs. 7,50,000, with an additional fee of Rs. 37,500.
If annual income is less than or equal to Rs. 12,50,000, your tax rate will be 20% of your
total income beyond Rs. 10,00,000, with an additional fee of Rs. 75,000.
If annual income is less than or equal to Rs. 15,00,000, your tax rate will be 25% of your
total income beyond Rs. 12,50,000, with an additional cost of Rs. 1,25,000.
If annual income exceeds Rs. 15,00,000, you will be taxed at 30% of the excess, with an
additional fee of Rs. 1,87,500.
Output:
Output:
NumList = []
Number = int(input("Please enter the Total Number of List Elements:
"))
for i in range(1, Number + 1):
value = int(input("Please enter the Value of %d Element : " %i))
NumList.append(value)
NumList.sort()
print('ORIGINAL LIST AFTER SORING:',NumList)
print("The third Smallest Element in this List is : ", NumList[2])
print("The third Largest Element in this List is : ", NumList[-3])
Ouput:
Please enter the Total Number of List Elements: 9
Please enter the Value of 1 Element : 15
Please enter the Value of 2 Element : 84
Please enter the Value of 3 Element : 75
Please enter the Value of 4 Element : 65
Please enter the Value of 5 Element : 32
Please enter the Value of 6 Element : 12
Please enter the Value of 7 Element : 48
Please enter the Value of 8 Element : 96
Please enter the Value of 9 Element : 1
ORIGINAL LIST AFTER SORING: [1, 12, 15, 32, 48, 65, 75, 84, 96]
The third Smallest Element in this List is : 15
The third Largest Element in this List is : 75
11. To find the sum of squares of the first 10 natural numbers.
Output:
for i in range(1,r+1):
Output:
Enter number: 8
Enter range of multiples:6
The multiples are:
8 16 24 32 40 48
13. To count the number of vowels in user entered string.
string=input("Enter string:")
vowels=0
for i in string:
vowels=vowels+1
print(vowels)
Output:
Enter string:informatics
4
14. To print the words starting with a alphabet in a user entered string.
found = False
words = s.split()
if word.startswith(a):
print(word)
found = True
if (found == False):
alphabet")
Output:
in
15. To print number of occurrences of a given alphabet in each string.
Output-1:
Output-2:
statesAndCapitals = {
'Gujarat' : 'Gandhinagar',
'Maharashtra' : 'Mumbai',
'Rajasthan' : 'Jaipur',
'Bihar' : 'Patna'
}
Output:
Output:
Enter number of students :4
Enter names of student :sai
Enter marks :56
Enter marks :85
Enter marks :96
Enter marks :45
Enter marks :78
Enter names of student :kumar
Enter marks :56
Enter marks :96
Enter marks :85
Enter marks :74
Enter marks :29
Enter names of student :anil
Enter marks :63
Enter marks :96
Enter marks :23
Enter marks :65
Enter marks :45
Enter names of student :reddy
Enter marks :98
Enter marks :97
Enter marks :95
Enter marks :96
Enter marks :91
Dictionary of student created :
{'sai': [56.0, 85.0, 96.0, 45.0, 78.0], 'kumar': [56.0, 96.0, 85.0,
74.0, 29.0], 'anil': [63.0, 96.0, 23.0, 65.0, 45.0], 'reddy': [98.0,
97.0, 95.0, 96.0, 91.0]}
d={1:100,2:20,3:500,4:66,5:800,6:3}
max_no=max(d.values())
min_no=min(d.values())
Output: