Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace ConsoleApplication22
- {
- class Program
- {
- static void Main(string[] args)
- {
- int n = int.Parse(Console.ReadLine());
- Console.WriteLine("{0}{1}{0}", new string('.', n - 1) , new string('*', 1)) ;
- int od = n - 2;
- int id = 1;
- for (int i = 1; i <= n - 1 ; i++ )
- {
- Console.WriteLine("{0}*{1}*{0}" , new string('.',od) , new string('.', id));
- od--;
- id += 2;
- }
- Console.WriteLine(new string('*', n * 2 -1));
- for (int i = 1; i <= n / 4; i++)
- {
- Console.WriteLine('*' + new string('.', n * 2 - 3) + '*');
- }
- for (int i =1; i <= n/2 ;i++)
- {
- Console.WriteLine("*{0}{1}{0}*", new string('.', n / 2), new string('*', n - 3));
- }
- for (int i = 1; i <= n / 4; i++)
- {
- Console.WriteLine('*' + new string('.', n * 2 - 3) + '*');
- }
- Console.WriteLine(new string('*',n*2-1));
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement