KEMBAR78
Informatics Practices - Practical File o o | PDF | Numbers | Area
0% found this document useful (0 votes)
7 views32 pages

Informatics Practices - Practical File o o

Ishrat Kaur Notay from Class XI-Science at Learning Paths School has completed her Informatics Practices practical file for the academic year 2024-2025. The document includes an index of programming exercises covering various topics such as Python fundamentals, data handling, flow control, list manipulation, and dictionaries. Each chapter contains multiple programming tasks designed to enhance students' coding skills.

Uploaded by

ishrat4488
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views32 pages

Informatics Practices - Practical File o o

Ishrat Kaur Notay from Class XI-Science at Learning Paths School has completed her Informatics Practices practical file for the academic year 2024-2025. The document includes an index of programming exercises covering various topics such as Python fundamentals, data handling, flow control, list manipulation, and dictionaries. Each chapter contains multiple programming tasks designed to enhance students' coding skills.

Uploaded by

ishrat4488
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 32

CERTIFICATE

This is to certify that Ishrat Kaur Notay of Class


XI-Science, Learning Paths School has
successfully completed her Informatics Practices
practical file during the academic session 2024-
2025.

1
Signatures: _______________

2
INDEX
CONTENTS
Chapter Questions Page
Chapter 3 1. Write a program to input a welcome message 5
and print it.
Python 2. Program to obtain three numbers and print their
Fundamental sum.
s 3. Program to obtain length and breadth of a
rectangle and calculate its area.
4. Program to calculate BMI of a person
5. Write a program to input a number and print its
cube.
6. Write a program to input a value in kilometres and 6
convert it to miles.
7. Write a program to input a value in tonnes and
convert it into quintals
8. Write a program to enter a small poem and print
it.
9. Write a program to input two numbers and swap
them.
10. Write a program to input three numbers to swap
them.
Chapter 4 1. Write a program to calculate area and 7
perimeter of a parallelogram.
Data 2. Write a program to calculate the amount
Handling payable if money has been lent on simple
interest.
3. Calculate formula of a triangle of sides 17,
23, 30 using heron’s formula.
4. Write program to calculate perimeter of a
triangle.
5. Write program to calculate sale price of an 8
item with given price and discount.
6. Write a program to calculate compound
interest.
Chapter 5 1. Write a program that takes in a number and 9
checks if it is odd or even.
Flow of 2. Program to accept three integers and print the
Control largest of the three. Make use of only the if
statement.
3. Program that takes three numbers and
calculates two sums as per this: Sum 1 – sum of
all inputted numbers. Sum 2 – sum of all non-
duplicate numbers in the input.
4. Program to check divisibility of a number with 10
another number.

3
5. Program to find multiples of a number out of
given five numbers.
6. Program to display a menu for calculating the 11
area or perimeter of a circle.
7. Program that reads two numbers and an
arithmetic operator and displays the computed
result.
8. Program that reads three integers and prints 12
them in ascending order.
9. Program to print whether an inputted character
is an uppercase letter, lowercase letter, digit or
a special character.
10. Program to calculate and print the roots of
quadratic equation ax^2 + bx + c = 0 (a is not
equal to zero).
11. Program to print the table 5. 13
12. Program to print sum of natural numbers upto 7
and print the sum progressively.
13. Program to print the sum of natural numbers
upto 7.
Chapter 6 1. Extract two list slices out of a given list of 14
numbers. Display and print the sum of the
List elements of first list slice which contains every
Manipulation other element from index 5 to 15. Program
should also display the average of elements in
second list slice that contains every fourth
element of the list. Given list contains numbers
from 1 to 20.
2. Write a program to copy a list and add 10 to the
first and last elements to the copy of list, then
display the lists.
3. Write a program to input number or a list to be 15
appended to a given list. Whether user enters a
number or a list, the list should append
accordingly.
4. Write a program that displays options for
deleting an element from a given list with
option for: deleting by value, deleting by
position or deleting a portion.
5. Write a program that inputs a list, replicates it 16
twice and sorts replicated list by ascending and
descending order.
6. Program to find the minimum element from a
list of elements along with its index.
7. Program to calculate mean of all numbers in a
list
8. Program to search for an element in a given list
of numbers.
9. Program to count frequency of a given element 17
in a list of numbers.
10. Program to check if maximum element in a list
lies in first or second half of a list.
11. Program to input two lists and check for the
maximum element amongst both of them. Then
display the element along with its position in its

4
list.
12. Write a program to find the largest/smallest
value in a given list of assets of a company
13. Write a program to input a list of numbers and 18
swap elements at the even location with the
elements in the odd locations.
14. A company’s assets, liabilities and capital
details are available in the form of three lists.
Write a program to test of the accounting
equation holds true for the company or not.
15. Given a list of integers, L, write a program to
calculate and display the sum of all the odd
numbers in the list.
16. Write a program to input a list of numbers and
ask for a new element and its position. Then
insert the element in the provided position.
17. Write a program to find the second largest 19
liability of a list of liabilities.
18. Write a program to input a list and two numbers
M, N. Then create a list from those elements of
the list which are divisible by both M and N.
Chapter 7 1. Write a program to read roll numbers of four 20
students and create a dictionary from it having
Dictionaries roll numbers as keys. Then modify the program
to check if the roll number two has scored more
than 75 marks
2. Write a program to create a dictionary for all
your friends and print a key value pair in
separate lines.
3. Given a dictionary M which stores marks of
students of class with roll numbers as the keys
and marks as the values. Write a program to
check if anyone has scored marks as 89.9.
4. Write a program to create a dictionary M which 21
stores the marks of class with roll numvers as
the keys and marks as values. Get the number
of students as input. Modify the program so
that one can modify marks if a roll number.
Obtain the roll number as input.
5. Write a program to create a dictionary namely
Numerals from the given lists.
6. Write a program to add new students’ roll
numbers and marks in the dictionary M created
with roll numbers as the keys and marks as the
values
7. Program that reads two numbers and an
arithmetic operator and displays the computed
result.
8. Write a program to create a dictionary 22
containing names of competition winner as
keys and number of their wins as values.
9. Consider already created dictionary M that
stores roll number and marks. Write a program
to input a roll number and delete it from the
dictionary. Display error message if roll number

5
doesn’t exist in the dictionary.
10. Create a dictionary where key value pairs are
available in three different lists as [1, 67.8], [2,
78.8], [3, 72.5].
11. A dictionary stores roll_numbers:names of 23
students who have been selected to participate
in national event. Modify program to display roll
numbers and names of selected students.
Chapter 9 1. Creating a database 26
2. Creating a table and viewing the schema.
Structured 3. Inserting Data into the table. =
Query 4. Viewing the table.
Language 5. Creating a table from another table.
(SQL) APPLICATION-BASED QUESTIONS 2
1. Create the table department based on the 7
following table instance chart.
2. Create table employee based on the following
instance chart.
3. Write a query to display ename and sal for 2
employees with salary more than 2200. 8
4. Write a query to display details of employees
who are not getting commission.
5. Write a query to display name and salary of
employees whose salary is not between 2500 to
4000.
6. Write a query to display name, job title and
salary of an employee who doesn’t have a
manager.
7. Write a query to display name of employee 2
whose name contains A as third alphabet. 9
8. Write a query to display name of employee
whose name ends with ‘n’.
9. Write a query to display name of employee with
name starting with s and having 4th letter t.
10. Write SQL commands for the following
questions on the basis of the table ‘STUDENT’.
11. Write SQL commands for the following 3
questions on the basis of the table ‘SPORTS’. 0
12. Write SQL commands for the following
questions on the basis of the table ‘CLUB’.

6
CHAPTER-3
PYTHON FUNDAMENTALS

1. Write a program to input a welcome message and print it.

2. Program to obtain three numbers and print their sum.

3. Program to obtain length and breadth of a rectangle and calculate its area.

4. Program to calculate BMI of a person.

5. Write a program to input a number and print its cube.

7
6. Write a program to input a value in kilometres and convert it to miles.

7. Write a program to input a value in tonnes and convert it into quintals.

8. Write a program to enter a small poem and print it.

9. Write a program to input two numbers and swap them.

10. Write a program to input three numbers and swap them

8
CHAPTER-4
DATA HANDLING

1. Write a program to calculate area and perimeter of a parallelogram.

2. Write a program to calculate the amount payable if money has been lent
on simple interest.

3. Calculate formula of a triangle of sides 17, 23, 30 using heron’s formula.

4. Write program to calculate perimeter of a triangle.

9
5. Write program to calculate sale price of an item with given price and
discount.

6. Write a program to calculate compound interest.

10
CHAPTER-5
FLOW OF CONTROL

1. Write a program that takes in a number and checks if it is odd or even.

2. Program to accept three integers and print the largest of the three. Make
use of only the if statement.

3. Program that takes three numbers and calculates two sums as per this: Sum
1 – sum of all inputted numbers. Sum 2 – sum of all non-duplicate numbers
in the input.

11
4. Program to check divisibility of a number with another number.

5. Program to find multiples of a number out of given five numbers.

12
6. Program to display a menu for calculating the area or perimeter of a circle.

7. Program that reads two numbers and an arithmetic operator and displays
the computed result.

13
8. Program that reads three integers and prints them in ascending order.

9. Program to print whether an inputted character is an uppercase letter,


lowercase letter, digit or a special character.

10. Program to calculate and print the roots of quadratic equation ax^2 + bx +
c = 0 (a is not equal to zero).

14
11. Program to print the table 5.

12. Program to print sum of natural numbers up to 7 and print the sum
progressively.

13. Program to print the sum of natural numbers up to 7.

15
CHAPTER-6
LIST MANIPULATION

1. Extract two list slices out of a given list of numbers. Display and print the
sum of the elements of first list slice which contains every other element
from index 5 to 15. Program should also display the average of elements in
second list slice that contains every fourth element of the list. Given list
contains numbers from 1 to 20.

2. Write a program to copy a list and add 10 to the first and last elements to
the copy of list, then display the lists.

16
3. Write a program to input number or a list to be appended to a given list.
Whether user enters a number or a list, the list should append accordingly.

4. Write a program that displays options for deleting an element from a given
list with option for: deleting by value, deleting by position or deleting a
portion.

17
5. Write a program that inputs a list, replicates it twice and sorts replicated list
by ascending and descending order.

6. Program to find the minimum element from a list of elements along with its
index.

7. Program to calculate mean of all numbers in a list.

8. Program to search for an element in a given list of numbers.

18
9. Program to count frequency of a given element in a list of numbers.

10. Program to check if maximum element in a list lies in first or second half of a
list.

11. Program to input two lists and check for the maximum element amongst
both of them. Then display the element along with its position in its list.

19
12. Write a program to find the largest/smallest value in a given list of assets of
a company.

13. Write a program to input a list of numbers and swap elements at the even
location with the elements in the odd locations.

14. A company’s assets, liabilities and capital details are available in the form of
three lists. Write a program to test of the accounting equation holds true for
the company or not.

15. Given a list of integers, L, write a program to calculate and display the sum
of all the odd numbers in the list.

20
16. Write a program to input a list of numbers and ask for a new element and its
position. Then insert the element in the provided position.

17. Write a program to find the second largest liability of a list of liabilities.

18. Write a program to input a list and two numbers M, N. Then create a list
from those elements of the list which are divisible by both M and N.

21
CHAPTER-7
DICTIONARIES

1. Write a program to read roll numbers of four students and create a


dictionary from it having roll numbers as keys. Then modify the program to
check if the roll number two has scored more than 75 marks.

2. Write a program to create a dictionary for all your friends and print a key
value pair in separate lines.

3. Given a dictionary M which stores marks of students of class with roll


numbers as the keys and marks as the values. Write a program to check if
anyone has scored marks as 89.9.

22
4. Write a program to create a dictionary M which stores the marks of class
with roll numvers as the keys and marks as values. Get the number of
students as input. Modify the program so that one can modify marks if a roll
number. Obtain the roll number as input.

5. Write a program to create a dictionary namely Numerals from the following


two lists:
keys = [‘One’, ‘Two’, ‘Three’]
values = [1, 2, 3]

6. Write a program to add new students’ roll numbers and marks in the
dictionary M created with roll numbers as the keys and marks as the values.

7. A dictionary contains details of two workers with their names as keys and
other details in the form of dictionary as value. Write a program to print the

23
workers’ information in records format.

8. Write a program to create a dictionary containing names of competition


winner as keys and number of their wins as values.

9. Consider already created dictionary M that stores roll number and marks.
Write a program to input a roll number and delete it from the dictionary.
Display error message if roll number doesn’t exist in the dictionary.

10. Create a dictionary where key value pairs are available in three different
lists as [1, 67.8], [2, 78.8], [3, 72.5].

24
11. A dictionary stores roll_numbers:names of students who have been selected
to participate in national event. Modify program to display roll numbers and
names of selected students.

25
CHAPTER 9
STRUCTURED QUERY LANGUAGE (SQL)

1. Creating a database.

2. Creating a table and viewing the schema.

26
3. Inserting Data into the table.

4. Viewing the table.

27
5. Creating a table from another table.

APPLICATION-BASED QUESTIONS

1. Create the table department based on the following table instance chart.

2. Create table employee based on the following instance chart.

The following table will be used for the upcoming questions.

28
3. Write a query to display ename and sal for employees with salary more than
2200.

4. Write a query to display details of employees who are not getting


commission.

5. Write a query to display name and salary of employees whose salary is not
between 2500 to 4000.

29
6. Write a query to display name, job title and salary of an employee who
doesn’t have a manager.

7. Write a query to display name of employee whose name contains A as third


alphabet.

8. Write a query to display name of employee whose name ends with ‘n’.

9. Write a query to display name of employee with name starting with s and
having 4th letter t.

10. Write SQL commands for the following questions on the basis of the table
‘STUDENT’ given below.

StudentN Class Name GAME Grade1 SUPW Grade2


o.
10 7 Sameer Cricket B Photograp A
hy
11 8 Sujit Tennis A Gardening C
12 7 Kamal Swimmin B Photograp B
g hy

30
13 7 Veena Tennis C Cooking A
14 9 Archana Basketba A Literature A
ll
15 10 Arpit Cricket A Gardening C
a. Display names of students with grade ‘C’ in either GAME or SUPW.

b. Display games offered by the school.

c. Display SUPW taken up by students with name beginning with A.

11. Write SQL commands for the following questions on the basis of the table
‘SPORTS’ given below.

StudentN Class Name GAME1 Grade1 GAME2 Grade2


o.
10 7 Sameer Cricket B Swimmin A
g
11 8 Sujit Tennis A Skating C
12 7 Kamal Swimmin B Football B
g
13 7 Veena Tennis C Tennis A
14 9 Archana Basketba A Cricket A
ll
15 10 Arpit Cricket A Athletics C
a. Display names of students with grade ‘C’ in either GAME1 OR GAME2 or
both.

b. Display names of the students have the same game for Game1 or
Game2.

c. Display SUPW taken up by students with name beginning with A.

12. Write SQL commands for the following questions on the basis of the table
‘CLUB’ given below.

31
COACHID COACHNAME AGE GAME1 DATEOFAPP PAY SEX
1 KUKREJA 35 KARATE 27/03/1996 100 M
0
2 RAVINA 34 KARATE 20/01/1998 120 F
0
3 KARAN 34 SQUASH 19/02/1992 200 M
0
4 TARUN 33 BASKETBALL 01/01/1998 150 M
0
5 ZUBIN 36 SWIMMING 12/01/1998 750 M
6 KETAKI 36 SWIMMING 24/02/1998 800 F
7 ANKITA 39 SQUASH 20/02/1998 220 F
0
8 ZAREEN 37 KARATE 22/02/1998 110 F
0
9 KUSH 41 SWIMMING 13/01/1998 900 M
10 SHAILYA 37 BASKETBALL 19/02/1998 170 M
0
a. To show all information about swimming coaches in the club.

b. To list names of all the coaches with their date of appointment in


descending order.

c. To display a report showing coach name, pay, age, and bonus pay (15%
of pay) for all coaches.

32

You might also like