Friday 4 July 2014

Write C# code to display the asterisk pattern as shown below:

*****
*****
*****
*****
*****
Solution:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Csharp_exercises
{
class Program
{
static void Main(string[] args)
{

   Console.WriteLine("*****");
   Console.WriteLine("*****");
   Console.WriteLine("*****");
   Console.WriteLine("*****");
   Console.WriteLine("*****");
   Console.ReadLine();
 
        }
    }
}

No comments:

Post a Comment