StoyanVitanov

Untitled

Jan 6th, 2017
144
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.30 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.  
  7. namespace ConsoleApplication2
  8. {
  9.     class Program
  10.     {
  11.         static void Main(string[] args)
  12.         {
  13.             int n = int.Parse(Console.ReadLine());
  14.  
  15.             Console.WriteLine("{0}/|\\{0}", new string('.', (n * 2) - 1));
  16.             Console.WriteLine("{0}\\|/{0}", new string('.', (n * 2) - 1));
  17.             Console.WriteLine("{0}***{0}", new string('.', (n * 2) - 1));
  18.  
  19.             int dots1 = (n * 2) - 2;
  20.             int dashes1 = 1;
  21.             for (int i = 1; i <= (n * 2) - 2; i++)
  22.             {
  23.                 Console.WriteLine("{0}*{1}*{1}*{0}",
  24.                     new string('.', dots1),
  25.                     new string('-', dashes1));
  26.                 dots1--;
  27.                 dashes1++;
  28.             }
  29.             Console.WriteLine("*{0}*{0}*", new string('-', (n * 2) - 1));
  30.             Console.WriteLine(new string('*', (n * 4) + 1));
  31.             for(int i = 1; i < 2; i++)
  32.             {
  33.                 for (int p = 1; p <= (n * 2);p++)
  34.                 {
  35.                     Console.Write("*.");
  36.                 }
  37.                 Console.WriteLine("*");
  38.             }
  39.             Console.WriteLine(new string('*', (n * 4) + 1));
  40.         }
  41.     }
  42. }
Add Comment
Please, Sign In to add comment