Gadget Corner, Huawei stock ROMs, Miracle Box, How To Install, Clone Firmware, Android Latest Version, HTC Firmware Flash File, and more information about gadgets for you

C# Program to Print shapes diamond | half diamond

C# Program to Print shapes diamond | half diamond - Welcome to the blog Gadget Corner we provide a lot of latest gadget information that must be very loss for you to miss, now we will discuss first about C# Program to Print shapes diamond | half diamond we have collected a lot of information to make this article complete for you, Ok please read::

You can also see our article on:


C# Program to Print shapes diamond | half diamond

C# Program to Print shapes

Program Statement:
Write a program using for loop which prints the following output on the screen.
*
**
***
****
***
**
*

Solution:
 static void Main(string[] args)
{
for (int i = 0; i <= 3; i++)
{
for (int j = 0; j <= i; j++)
{
Console.Write("*");
}
Console.WriteLine();

}
for (int i = 3; i >0; i--)
{
for (int j = 0; j <= i-1; j++)
{
Console.Write("*");
}
Console.WriteLine();

}
Console.ReadLine();}



Articles about C# Program to Print shapes diamond | half diamond finished discussed

We think it is enough information about C# Program to Print shapes diamond | half diamond, hopefully the information we give can give benefit for you,

If you feel the information C# Program to Print shapes diamond | half diamond that we provide can provide benefits for others please share with link https://darellsfinancialcorner.blogspot.com/2013/12/c-program-to-print-shapes-diamond-half.html thank you for visiting our blog page and do not forget to visit other

Share on Facebook
Share on Twitter
Share on Google+
Tags :

Related : C# Program to Print shapes diamond | half diamond

0 komentar:

Posting Komentar