Gradient

Courses

∇\nabla∇The maths behind AI0/72
π\piπMaths0/84
⋆\star⋆AI for everyone0/10
Γ\GammaΓGame theory0/49
py\texttt{py}pyPython for AI0/15
y^\hat{y}y^​Build your own AI0/15
All courses

Tuition

My tuitionOlympiad trackCompetitions

Practice

ProjectsAsk a questionTrain on a GPUExplorationsMaths StoriesUnsolved problemsPlaygroundScience labsMock testsOlympiad

Reference

GlossaryBlogDiscoveries
Practice › Class 9 › Computer Science

Boolean logic: practice questions

Class 9 Computer Science. Ten questions with step-by-step answers, for CBSE and ICSE. Try each one before you open its answer.

Practise this with your AI tutorGo to the questions

Key ideas

  • AND, OR and NOT.
  • These are the multi-step questions examiners like to set. Read each one twice, write down what you know, then plan before you calculate.
  • These go beyond the syllabus. Each one has a neat idea that makes it short; brute force is slow.

Read each question twice and say the answer out loud before you check it. For code or binary questions, work it out on paper step by step, the way a computer would.

Ten questions

  1. 1.XOR(0, 0) = ?

    Show the answer

    Think: AND needs both, OR needs either.

    Work: XOR truth table.

    Answer: 0

  2. 2.A = true, B = true, C = true. (A and not B) or C?

    1. A.true
    2. B.false
    Show the answer

    Think: not flips the value.

    Work: Work out the brackets first.

    Answer: true

  3. 3.NAND(1, 0) = ?

    Show the answer

    Think: AND needs both, OR needs either.

    Work: NAND truth table.

    Answer: 1

  4. 4.A = true, B = false, C = true. (A and not B) or C?

    1. A.true
    2. B.false
    Show the answer

    Think: not flips the value.

    Work: Work out the brackets first.

    Answer: true

  5. 5.NOR(0, 1) = ?

    Show the answer

    Think: AND needs both, OR needs either.

    Work: NOR truth table.

    Answer: 0

  6. 6.A = false, B = false, C = true. (A and not B) or C?

    1. A.false
    2. B.true
    Show the answer

    Think: not flips the value.

    Work: Work out the brackets first.

    Answer: true

  7. 7.XOR(1, 1) = ?

    Show the answer

    Think: AND needs both, OR needs either.

    Work: XOR truth table.

    Answer: 0

  8. 8.A = false, B = true, C = true. (A and not B) or C?

    1. A.true
    2. B.false
    Show the answer

    Think: not flips the value.

    Work: Work out the brackets first.

    Answer: true

  9. 9.XOR(1, 0) = ?

    Show the answer

    Think: AND needs both, OR needs either.

    Work: XOR truth table.

    Answer: 1

  10. 10.A = false, B = true, C = false. (A and not B) or C?

    1. A.false
    2. B.true
    Show the answer

    Think: not flips the value.

    Work: Work out the brackets first.

    Answer: false

Before you check an answer

  • AND needs both, OR needs either.
  • not flips the value.

Questions students ask

What does Boolean logic in Class 9 Computer Science cover?
AND, OR and NOT. These are the multi-step questions examiners like to set. Read each one twice, write down what you know, then plan before you calculate. These go beyond the syllabus. Each one has a neat idea that makes it short; brute force is slow.
How should I practise Boolean logic?
Read each question twice and say the answer out loud before you check it. For code or binary questions, work it out on paper step by step, the way a computer would. Try all ten questions on this page, then open the chapter in Gradient tuition for step-by-step lessons, a live experiment and an AI tutor who explains where you went wrong.
Is this for CBSE or ICSE?
The questions follow the Class 9 Computer Science syllabus shared by CBSE and ICSE / ISC, and suit most state boards too.

Stuck on one of these?

Gradient tuition teaches Boolean logic step by step, with experiments you can play with and an AI tutor who circles the part of the question you missed.

Open Boolean logic in tuition
LoopsCyber safety