Console Application for creating star pyramid using C# code
by uosɐɾ McArthur
// Console Application for creating star pyramid using C# code
// For value of 4
// *
// * *
// * * *
// * * * *
using System;
namespace STAR
{
class Class1
{
static void Main()
{
Console.WriteLine(“Enter the value “);
int k=int.Parse(Console.ReadLine());
int n=k-1;
int x=2*(k-1)+1;
for(int p=0;p
{
for(int j=k-1;j>=0;j–)
{
Console.Write(” “);
}
for(int i=0;i
{
if(i%2==1)
{
Console.Write(“*”);
}
else
{
Console.Write(” “);
}
}
Console.WriteLine();
k–;
}
Console.ReadLine();
}
}
}
Written by xxris
|
|
|
|
|
|
More posts from us
- Sony Playstation 3 Accessories Must Needed Tools For Great Joy
- Console Application using Operator Overload in C# 1.1 and 2.0 (Dot Net)
- Advantages of digital mixing consoles
Other links you might like
- New Thanksgiving Virgin Mobile Promo Code Now Live At 25 Percent Off
- ViewSonic ViewPad E70 Tablet with ICS for $169 Only
Incoming search terms:
- c# create star piramid
- piramid console c#
- program pyramid pascal using c#
- programing of star pyrimid in c# net console application
- pyramid * in c#
- pyramid star using C#
- pyrimid program coding in console application in c#
- star application c#
- star pyramid in console application
- star pyramid program in c