Created
February 15, 2018 08:29
-
-
Save algorythm/e3a740e6fc6f4383e628f0096a4861ed to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void SleepSort(int[] list) | |
{ | |
foreach (var i in list) | |
{ | |
Task.Run(() => | |
{ | |
Thread.Sleep(i); | |
Console.Write($"{i} "); | |
}); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment