Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Diagnostics;
- using System.Threading;
- namespace ConsoleApplication1
- {
- class Program
- {
- static void Main(string[] args)
- {
- Stopwatch stopWatch = new Stopwatch();
- stopWatch.Start();
- int[,] arr = new int[10000, 10000];
- for (int i = 0; i < arr.GetLength(0); i++)
- for (int j = 0; j < arr.GetLength(1); j++)
- arr[i, j] = ((i + 1) * j);
- for (int i = 0; i < arr.GetLength(0); i++)
- for (int j = 0; j < arr.GetLength(1); j++)
- Console.Write(" {0}", arr[i, j]);
- stopWatch.Stop();
- TimeSpan ts = stopWatch.Elapsed;
- string elapsedTime = String.Format("{0:00}:{1:00}:{2:00}.{3:00}", ts.Hours, ts.Minutes, ts.Seconds, ts.Milliseconds / 10);
- Console.WriteLine("RunTime " + elapsedTime);
- Console.ReadKey();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement