Easy csharp

Print numbers 1 to 13

Problem

Print all integers from 1 to 13 on one line.

Hints
  • for (int i = 1; i <= n; i++)

Your practice code

Ready — edit the code above and click Run.

Solution

using System;

class Program
{
    static void Main()
    {
        int n = 13;
        for (int i = 1; i <= n; i++)
            Console.Write(i + (i < n ? " " : ""));
    }
}

Try solving on your own first, then reveal the official answer.

Explanation

Classic warm-up loop.

Toolliyo Assistant
Ask about tutorials, ebooks, training, pricing, mentor services, and support. I use public site content only—not admin or internal tools.

care@toolliyo.com

Need callback? Share your details