Bird
0
0

Which symbol is used to start a single-line comment in Kotlin?

easy📝 Conceptual Q1 of 15
Kotlin - Basics and JVM Runtime
Which symbol is used to start a single-line comment in Kotlin?
A//
B/*
C#
D<!--
Step-by-Step Solution
Solution:
  1. Step 1: Understand single-line comment syntax

    In Kotlin, single-line comments start with two forward slashes.
  2. Step 2: Identify correct symbol

    The symbol '//' is used to comment out a single line.
  3. Final Answer:

    // -> Option A
  4. Quick Check:

    Single-line comment symbol = // [OK]
Quick Trick: Single-line comments start with double slashes // [OK]
Common Mistakes:
MISTAKES
  • Using /* for single-line comments
  • Using # which is not Kotlin syntax
  • Using HTML comment syntax Basics and JVM Runtime" in Kotlin

9 interactive learning modes - each teaches the same concept differently

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Kotlin Quizzes