Darwis Techno, MRT Dongle MTK Tool, AT&T to Compete with Verizon, Android TV, latest KitKat, stock firmware, Oppo Update Version Firmware Flash, Android Jelly Bean

C# Program to Print Triangle in Square

C# Program to Print Triangle in Square - every day there is always the latest gadget that is born, if we do not update the information then we will be outdated, even though we do not have the gadget but at least we know the information, on the blog Darwis Techno we are discussing a lot of information from various brands gadgets, now we will discuss first about C# Program to Print Triangle in Square we have gathered information to make this article, please read to finish

Articles : C# Program to Print Triangle in Square
full Link : C# Program to Print Triangle in Square
Article Csharp, Article programs,

You can also see our article on:


C# Program to Print Triangle in Square

C# Program to Print Triangle in Square

Program Statement:
Write a program which display the following output on the screen.
####$####
###$#$###
##$###$##
#$#####$#
$#######$

Solution:
 class shape
{
int x, y;
public void sh()
{
Console.WriteLine();
for (x = 1; x <= 5; x++)
{
for (y = 1; y <= 5 - x; y++)
{
Console.Write("#");
}
Console.Write("$");
for (y = 2; y <= x * 2 - 1; y++)
{
Console.Write("#");
}
Console.Write("\b$");
for (y = 1; y <= 5 - x; y++)
{
Console.Write("#");
}
Console.WriteLine("\n");
}
}
}




information C# Program to Print Triangle in Square has been completed in the discussion

hopefully the information C# Program to Print Triangle in Square can provide benefits for you in providing information about the latest gadgets from various brands,

you just read the article about C# Program to Print Triangle in Square if you intend to bookmark or share this information can use link http://laladarwis.blogspot.com/2013/12/c-program-to-print-triangle-in-square.html thank you and do not forget to get back other information

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

Related : C# Program to Print Triangle in Square

0 komentar:

Post a Comment