Tsallaka zuwa abun ciki
Justice Tech School

C# Comments

Use // for a single line and /* */ for several lines. Lines starting with /// hold XML documentation that editors show as tooltips.

Example
// single line
/* multiple
   lines */
/// <summary>Adds two numbers.</summary>
int Add(int a, int b) => a + b;

Exercise

Start a single line comment.

 comment

Quiz Test

Which marks a single line comment?

These free lessons are for learning. Join a full course for projects, mentor feedback and a verified certificate.