C# Program to Print Triangle in Square

C# Program to Print Triangle in Square - is the information you are looking for, and in the blog Google News we have provided her, all right in this article titled C# Program to Print Triangle in Square we will discuss it in full, in addition to the information we have also provided a lot of info about the latest gadgets and a wide range of tips and tricks that according to the gadget you are using, well please continue reading:

Penyanyi : C# Program to Print Triangle in Square
Judul lagu : 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");
}
}
}




Demikianlah Artikel C# Program to Print Triangle in Square

Sekian Kunci gitar C# Program to Print Triangle in Square , mudah-mudahan bisa memberi manfaat untuk anda semua. baiklah, sekian postingan Chord gitar lagu kali ini.

Anda sedang membaca artikel C# Program to Print Triangle in Square dan artikel ini url permalinknya adalah https://googledoodlenewstoday.blogspot.com/2013/12/c-program-to-print-triangle-in-square.html Semoga artikel ini bisa bermanfaat.

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

Related : C# Program to Print Triangle in Square

  • C# Program to solve different problemsC# Program to solve different problemsProgram Statement:Write a program which will take input a character ‘a’ value from user. You have to use switch statement to decide ...
  • C# program to print nth iteration using loopsC# program to print 1 2 2 3 3 3 4 4 4 4 5 5 5 5 5 6 6 6 6 6 6 . . . nth iterationProblem Statement:Write a program using loop which prints the following output.1 2 2 3 3 ...
  • How to View Source Code of .NET EXEHow to View Source Code of .NET EXE.NET one of the most familiar word for developers/programmers and CS/IT students. Many of you want to see .NET source code, so if you ...
  • C# Program to Print TrianglesC# Program to Print TrianglesProgram Statement:Write a program to produce the following output:A B C D E F G F E D C B AA B C D E F     F E D C B AA B C D E &n ...
  • C# Program to check number is prime or composite C# Program to check entered number is prime or composite Program Statement:Write a program that takes an integer as an input from user and prints if it is a prime o ...

1 komentar:

  1. As a beginner programmer, I want to say that I often face difficulties. Especially when you have to correct someone else's code. For a site that represents interests of apps store optimization, I try to find the maximum amount of information to share with people like me. Thank you for the useful information.

    BalasHapus