joel838
joel838 7d ago β€’ 10 views

Multiple choice questions on Comparison Operators in JavaScript for Grade 7

Hey there! πŸ‘‹ Learning about comparison operators in JavaScript can be super useful for making your code do cool things! Think of them as tools to check if things are equal, bigger, or smaller. Let's dive into a quick guide and then test your knowledge with a fun quiz! Good luck! 😊
πŸ’» Computer Science & Technology

1 Answers

βœ… Best Answer
User Avatar
scott.bethany71 Jan 1, 2026

πŸ“š Quick Study Guide

  • πŸ”’ What are Comparison Operators? These operators compare two values and return a boolean result (true or false).
  • βœ… Equal to (==): Checks if two values are equal, but it doesn't check the data type. For example, 5 == "5" is true.
  • πŸ’― Strict Equal to (===): Checks if two values are equal AND of the same data type. For example, 5 === "5" is false because one is a number and the other is a string.
  • βœ”οΈ Not Equal to (!=): Checks if two values are not equal. Like ==, it doesn't check the data type.
  • 🚫 Strict Not Equal to (!==): Checks if two values are not equal OR are not of the same data type.
  • πŸ“ˆ Greater Than (>): Checks if the left value is greater than the right value. For example, 10 > 5 is true.
  • πŸ“‰ Less Than (<): Checks if the left value is less than the right value. For example, 5 < 10 is true.
  • πŸ“š Greater Than or Equal To (>=): Checks if the left value is greater than or equal to the right value. For example, 10 >= 10 is true.
  • πŸ”’ Less Than or Equal To (<=): Checks if the left value is less than or equal to the right value. For example, 5 <= 10 is true.

πŸ–₯️ Practice Quiz

  1. What does the == operator do in JavaScript?
    1. A. Checks if two values are exactly the same.
    2. B. Checks if two values are equal, ignoring data type.
    3. C. Assigns a value to a variable.
    4. D. Checks if two values are not equal.
  2. Which operator checks if two values are equal AND of the same data type?
    1. A. ==
    2. B. !=
    3. C. ===
    4. D. =
  3. What will 10 > 5 evaluate to?
    1. A. false
    2. B. true
    3. C. null
    4. D. undefined
  4. What will 5 < 2 evaluate to?
    1. A. true
    2. B. false
    3. C. null
    4. D. undefined
  5. What does the >= operator check?
    1. A. If the left value is greater than the right value.
    2. B. If the left value is less than the right value.
    3. C. If the left value is greater than or equal to the right value.
    4. D. If the left value is less than or equal to the right value.
  6. Which operator means 'not equal to' without considering data type?
    1. A. ===
    2. B. ==
    3. C. !=
    4. D. !==
  7. What will `"7" === 7` evaluate to?
    1. A. true
    2. B. false
    3. C. null
    4. D. undefined
Click to see Answers
  1. B
  2. C
  3. B
  4. B
  5. C
  6. C
  7. B

Join the discussion

Please log in to post your answer.

Log In

Earn 2 Points for answering. If your answer is selected as the best, you'll get +20 Points! πŸš€