Practice Conditional Statements - 1.3 | Chapter 8: Statements and Scope | ICSE Class 12 Computer Science
Students

Academic Programs

AI-powered learning for grades 8-12, aligned with major curricula

Professional

Professional Courses

Industry-relevant training in Business, Technology, and Design

Games

Interactive Games

Fun games to boost memory, math, typing, and English skills

Conditional Statements

1.3 - Conditional Statements

Enroll to start learning

You’ve not yet enrolled in this course. Please enroll for free to listen to audio lessons, classroom podcasts and take practice test.

Learning

Practice Questions

Test your understanding with targeted questions

Question 1 Easy

Write an if statement that prints 'Hello' if a variable x is greater than 10.

💡 Hint: Think about the condition you're checking.

Question 2 Easy

Create an if-else statement that checks if a number is even or odd.

💡 Hint: Use the modulus operator %.

4 more questions available

Interactive Quizzes

Quick quizzes to reinforce your learning

Question 1

What does an if statement do?

Executes code based on true condition
Always executes
Never executes

💡 Hint: Remember the conditional nature of if statements.

Question 2

True or False: An if-else statement is used when you want to handle one condition only.

True
False

💡 Hint: Consider what happens when the condition is false.

2 more questions available

Challenge Problems

Push your limits with advanced challenges

Challenge 1 Hard

Write a program that takes an input of grades and provides feedback such as 'Excellent', 'Good', or 'Needs Improvement' based on the grade ranges.

💡 Hint: Use elif to handle multiple outcomes based on the input grade.

Challenge 2 Hard

Create a program that checks the weather condition from user input and responds differently based on conditions like 'rain', 'sunny', or 'cloudy'.

💡 Hint: Use if-elif to give multiple responses based on specific inputs.

Get performance evaluation

Reference links

Supplementary resources to enhance your learning experience.