https://www.acmicpc.net/problem/10992
using System;
class Program
{
static void Main() {
int n=int.Parse(Console.ReadLine());
for(int i=1;i<n;i++){
for(int j=n-i;j>0;j--) Console.Write(" ");
Console.Write("*");
for(int j=0;j<(i-2)*2+1;j++) Console.Write(" ");
if(i!=1) Console.Write("*");
Console.WriteLine();
}
for(int i=0;i<(n-1)*2+1;i++) Console.Write("*");
}
}