Proposed exercise
Create a function which draws a parallelogram, with the width, height and character specified as parameters:
DrawParallelogram(10,4,'*');
would display
**********
**********
**********
**********
Solution
using System; class DParallelogram { static void DrawParallelogram(int width, int height, char character) { for (int i = 0; i < height; i++) { for (int j = 0; j < width; j++) Console.Write(character); Console.WriteLine(); for (int c = 0; c <= i; c++) Console.Write(" "); } }