using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace count
{
class Program
{
static void Main(string[] args)
{
Console.Write("Plase Input Base for glass : ");
int numbase = int.Parse(Console.ReadLine());
int result = 0;
for (int i = numbase; i >= 0; i--)
{
result += i;
}
Console.WriteLine("Result for all glass : {0}\nShow :", result);
for (int i = 1; i <= numbase; i++)
{
for (int j = 1; j <= i; j++)
{
Console.Write("*");
} Console.WriteLine();
}
}
}
}
ไม่มีความคิดเห็น:
แสดงความคิดเห็น
แสดงความเห็นเกี่ยวกับบทความตรงนี้นะ ^^