Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: f2060b2092
Fetching contributors…

Cannot retrieve contributors at this time

21 lines (20 sloc) 0.513 kb
using System;
namespace Fixie
public static class ArrayExtensions
//Fisher-Yates Shuffle
// C# implementation from
public static void Shuffle<T>(this T[] array, Random random)
int n = array.Length;
while (n > 1)
int k = random.Next(n--);
T temp = array[n];
array[n] = array[k];
array[k] = temp;
Jump to Line
Something went wrong with that request. Please try again.