0% found this document useful (0 votes)
3 views10 pages

Xi Practical File

The document outlines practical exercises for Class XI in Information Practices for the session 2025-26, covering various programming and SQL tasks. Each practical includes an aim, input/output examples, and calculations such as average, area, simple interest, and database operations. The exercises also involve data manipulation and retrieval using SQL commands for a student database.

Uploaded by

swatisaran890
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)
3 views10 pages

Xi Practical File

The document outlines practical exercises for Class XI in Information Practices for the session 2025-26, covering various programming and SQL tasks. Each practical includes an aim, input/output examples, and calculations such as average, area, simple interest, and database operations. The exercises also involve data manipulation and retrieval using SQL commands for a student database.

Uploaded by

swatisaran890
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

CLASS-XI

SUBJECT- IP PRACTICAL FILE


SESSION 2025-26
=======================================================
PRACTICAL – 1
Aim: To calculate average and grade.

OUTPUT-
Marks 1: 80
Marks 2: 75
Marks 3: 70
Marks 4: 85
Marks 5: 90
Grade B
PRACTICAL – 2
Aim: To calculate sale price after discount.

OUTPUT –
Cost Price: 1000
Discount %: 10
Sale Price: 900.0
PRACTICAL – 3
Aim: Area and perimeter of rectangle.

OUTPUT-
Length: 50
Breadth: 40
Area: 2000.0
Perimeter: 180.0
PRACTICAL – 4
Aim: Simple Interest.

OUTPUT-
Principal: 2000
Rate: 10
Time: 2
Simple Interest: 400.0

PRACTICAL – 5
Aim: Profit or Loss.

OUTPUT-
Cost Price: 200
Selling Price: 300
Profit: 100.0
PRACTICAL – 6
Aim: EMI calculation.

p=float(input("Amount: "))
r=float(input("Rate: "))
n=int(input("Time: "))
emi=(p*r*n)/100
print("EMI:",emi)

OUTPUT-
Amount: 1000
Rate: 2
Time: 3
EMI: 60.0
PRACTICAL – 7
Aim: GST calculation.

amt=float(input("Amount: "))
gst=amt*18/100
print("GST:",gst)

OUTPUT-
Amount: 5000
GST: 900.0

PRACTICAL – 8
Aim: Largest and Smallest number

lst=[10,25,5,40,15]
print("Largest:",max(lst))
print("Smallest:",min(lst))

OUTPUT-
Largest: 40
Smallest: 5
PRACTICAL – 9
Aim: Third largest number

lst=[10,20,5,40,15]
[Link]()
print("Third Largest:",lst[-3])

OUTPUT-
Third Largest: 15
PRACTICAL – 10
Aim: Sum of squares of first 100 natural numbers.
s=0
for i in range(1,101):
s+=i*i
print(s)

OUTPUT-
338350
PRACTICAL – 11
Aim: Multiplication Table

n=int(input("Number: "))
for i in range(1,11):
print(n,"x",i,"=",n*i)

OUTPUT-
Number: 7
7x1=7
7 x 2 = 14
7 x 3 = 21
7 x 4 = 28
7 x 5 = 35
7 x 6 = 42
7 x 7 = 49
7 x 8 = 56
7 x 9 = 63
7 x 10 = 70

PRACTICAL – 12
Aim: Count vowels.

s=input("Enter string: ")


c=0
for i in s:
if i in "aeiouAEIOU":
c+=1
print("Vowels:",c)

OUTPUT-

Enter string: holyfaithschool


Vowels: 5

PRACTICAL – 13
Aim: Words starting with given alphabet
s=input("Enter sentence: ")
for w in [Link]():
if w[0]=='a':
print(w)

OUTPUT-
Enter sentence: Hi... How are you?
are
PRACTICAL – 14
Aim: Count character

s=input("String: ")
ch=input("Character: ")
print([Link](ch))

OUTPUT-
String: holyfaithschool
Character: o
3
PRACTICAL – 15
Aim: State-Capital dictionary

d={"MP":"Bhopal","UP":"Lucknow","RJ":"Jaipur"}
print(d)

OUTPUT-
{'MP': 'Bhopal', 'UP': 'Lucknow', 'RJ': 'Jaipur'}
PRACTICAL – 15
Aim: Student-marks dictionary

stu={"Amit":78,"Ravi":85,"Neha":90}
print(stu)

OUTPUT-
{"Amit":78,"Ravi":85,"Neha":90}
PRACTICAL – 17
Aim: Highest & Lowest marks.

stu={"Amit":78,"Ravi":85,"Neha":90}
print("Highest:",max([Link]()))
print("Lowest:",min([Link]()))
OUTPUT-
Highest: 90
Lowest: 78
Data Management : SQL Commands
SQL PRACTICALS
Practical – 18
To create a database.

CREATE DATABASE school;

OUTPUT-
Query OK, 1 row affected
Practical – 19
To create student table with the student id, class, section, gender, name,
dob, and marks as attributes where the student id is the primary key.

CREATE TABLE student(


Rno INT PRIMARY KEY,
Name VARCHAR(20),
Class INT,
Section CHAR(1),
Gender VARCHAR(10),
DOB DATE,
Marks INT
);
OUTPUT-
Query OK, 0 rows affected
Practical – 20
To insert the details of at least 10 students in the above table.

INSERT INTO student VALUES


(1,'Amit',11,'A','Male','2005-03-12',78),
(2,'Ravi',11,'A','Male','2005-07-20',65),
(3,'Neha',11,'B','Female','2005-01-15',88),
(4,'Pooja',11,'A','Female','2005-11-10',92),
(5,'Rahul',11,'C','Male','2004-12-05',45),
(6,'Anita',11,'B','Female','2005-05-18',73),
(7,'Suresh',11,'C','Male','2005-09-02',55),
(8,'Kiran',11,'A','Male','2005-02-28',81),
(9,'Meena',11,'B','Female','2005-08-14',67),
(10,'Rohit',11,'C','Male','2005-06-30',49);
OUTPUT-
Query OK, 10 rows affected
Practical – 21
To display the entire content of table.

SELECT * FROM student;

OUTPUT-
Practical – 22
To display Rno, Name and Marks of those students who are scoring marks
more than 50.

SELECT Rno, Name, Marks FROM student WHERE Marks > 50;

OUTPUT-

Practical – 23
To display Rno, Name, DOB of those students who are born between ‘2005-
01-01’ and ‘2005-12-31’

SELECT Rno, Name, DOB


FROM student
WHERE DOB BETWEEN '2005-01-01' AND '2005-12-31';

OUTPUT-

You might also like