Advertisement
Guest User

Untitled

a guest
Oct 8th, 2017
274
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.46 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace ChristmasTree
  7. {
  8.     class Program
  9.     {
  10.         static void Main(string[] args)
  11.         {
  12.             int n = int.Parse(Console.ReadLine());
  13.             for (int i = 0; i <= n; i++)
  14.                {
  15.                 Console.WriteLine("{0}{1} | {1}{0}", new string(' ', n - i), new string('*', i));
  16.                }
  17.         }
  18.     }
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement