Advertisement
SSkrev

Numbers from 1 to n

Mar 17th, 2014
501
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.25 KB | None | 0 0
  1. using System;
  2.  
  3. class NumberFromOneToN
  4. {
  5.     static void Main()
  6.     {
  7.         Console.Write("n=");
  8.         int n = int.Parse(Console.ReadLine());
  9.         for (int i = 1; i <= n; i++)
  10.         {
  11.             Console.WriteLine(i);
  12.         }
  13.     }
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement