Skip to content

Instantly share code, notes, and snippets.

@Kiso-blg
Created March 13, 2016 09:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Kiso-blg/249e097aaddcfff7a527 to your computer and use it in GitHub Desktop.
Save Kiso-blg/249e097aaddcfff7a527 to your computer and use it in GitHub Desktop.
Basics Exam 20 December 2014
using System;
namespace Problem_2___Cheat_Sheet
{
class CheatSheet
{
static void Main(string[] args)
{
int rows = int.Parse(Console.ReadLine());
int cols = int.Parse(Console.ReadLine());
long verticalStart = long.Parse(Console.ReadLine());
long horizontalStart = long.Parse(Console.ReadLine());
for (long row = verticalStart; row < verticalStart + rows; row++)
{
for (long col = horizontalStart; col < horizontalStart + cols; col++)
{
Console.Write(row * col);
Console.Write((col < horizontalStart + cols - 1) ? " " : "");
}
Console.WriteLine();
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment