CLASS - VI
CHAPTER - 7 ( Control with Conditionals )
Worksheets
Multiple Choice Questions (MCQs).
Objective Type Questions
Using the below pseudocode answer the following questions(Question 1 to 4) :
IF (Day == Saturday OR Day == Sunday)
IF (Time >= 12 AM AND Time <=8 PM))
THEN Holiday
ELSE
School Day
ELSE
School day
END
Question 1 Today is Monday and time is 11.30 AM. Is today a school day?
Option 1 True
Option 2 False
Answer: Option 1
Question 2 Today is Saturday and time is 1.30 AM. Is today a Holiday?
Option 1 True
Option 2 False
Answer: Option 1
Question 3 Today is Wednesday and time is 5.30 AM. Is today a school day?
Option 1 True
Option 2 False
Answer: Option 1
Question 4 Today is Sunday and the time is 09.30 PM. Is today a Holiday?
Option 1 True
Option 2 False
Answer: Option 2
Question 5 Logical operators can be used to make decisions in our code
Option 1 True
Option 2 False
Answer: Option 1
Question 6 Which operator is used if the statement evaluates true only if both
the expressions are true
Option 1 And
Option 2 Or
Option 3 Not
Option 4 None of the above
Answer: Option 1
Question 7 Which operator is used if the statement evaluates true only if only
one of the expressions is true
Option 1 And
Option 2 Or
Option 3 Not
Option 4 None of the above
Answer: Option 2
Question 8 Which of the following operator is used to reverse or negate a
condition.
Option 1 And
Option 2 Or
Option 3 Not
Option 4 None of the above
Answer: Option 3
Based on the flowchart for Are you a teen, let us now try to answer the below questions.
Question 9 Your father’s age is 35. In which category will he fall?
Option 1 Child
Option 2 Teenager
Option 3 Adult
Option 4 None of the above
Answer: Option 3
Question 10 Your sister’s age is 19. In which category will she fall?
Option 1 Child
Option 2 Teenager
Option 3 Adult
Option 4 None of the above
Answer: Option 2
Short Answer Questions
1. What are the different types of logical operators? Explain with examples.
Answer: The different types of logical operators are AND, OR & NOT.
AND operator is used to determine if two
or more conditions are true. If all the
conditions are true, the AND operator
returns TRUE. If any one of the
conditions fail, the AND operator returns
FALSE. In some programming languages
AND operator is denoted by “&&”
symbol.
The OR operator is used to determine if
either one of two or more conditions is
TRUE. If any of the condition is true, the
OR operator returns TRUE. If all the
conditions fail, the OR operator simply
returns FALSE. In some programming
languages OR operator is denoted by
“||” symbol
NOT operator to reverse or
negate a condition. If the condition is
true, NOT will return false and viceversa. In some programming languages
NOT operator is denoted by “!” symbol.
2. Explain with example on how to combine different logical operators.
Answer: we need to combine different
logical operators to create a complex
expression. Imagine your library is open
on Monday between 10 AM to 12 PM OR
on Wednesday between 3 PM to 5 PM.