Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

DALY COLLEGE, INDORE

CLASS : XI SUBJECT : COMPUTER SCIENCE DATE : 24/04/2024


ASSIGNMENT # 2 (CONDITIONAL STATEMENTS)

Note : Use proper file name, variable names, comments & indentation.
Q.1 Write a program to check if a number is divisible by another number or
not.
Q.2 Write a program to take a year as input and check if it is a leap year or not.
Q.3 Write a program that reads two numbers and an operator and displays the
computed result.
Q.4 Write a program to compare two numbers and display bigger number.
Q.5 Write a program to calculate and print roots of a quadratic equation.
Q.6 Write a program to print whether a given character is an uppercase or a
lowercase character or a digit or any other character.
Q.7 Write a program to compare three numbers and print them in order.
Q.8 Write a program to calculate BMI of a person after inputting its weight in
kgs and height in meters then print the Nutritional Status as per following
table: (bmi = weight/height*height)
Nutritional Status WHO criteria BMI cut-off
Underweight <18.5
Normal 18.5 – 24.9
Overweight 25 – 29.9
Obese >= 30
Q.9 Write a program that accept the marks of the student in five subjects in
Class X and
a. All subjects marks
b. Total Marks Obtained
c. Percentage
d. Grade based on following table
Percentage of Marks Grade
Above 90% A
80% to 90% B
70% to 80% C
60% to 70% D
Below 60% E
********

You might also like