Bird
0
0

What does the '-' operator do in Kotlin?

easy📝 Conceptual Q2 of 15
Kotlin - Operators and Expressions
What does the '-' operator do in Kotlin?
ADivides two numbers
BSubtracts one number from another
CMultiplies two numbers
DFinds the remainder
Step-by-Step Solution
Solution:
  1. Step 1: Understand the subtraction operator

    The minus sign (-) subtracts one number from another in Kotlin.
  2. Step 2: Match the operator to its function

    Among the options, only subtraction matches the '-' operator.
  3. Final Answer:

    Subtracts one number from another -> Option B
  4. Quick Check:

    Subtraction operator = - [OK]
Quick Trick: Minus sign means subtract, like taking away [OK]
Common Mistakes:
MISTAKES
  • Thinking - means divide
  • Confusing - with remainder
  • Using - for multiplication

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Kotlin Quizzes