Shuffle List<T>

anon271334 picture anon271334 · Feb 20, 2010 · Viewed 20.8k times · Source

Possible Duplicate:
Randomize a List<T> in C#

I have a list which contains many thousands of FilePath's to locations of audio files, and was wondering which would be the most efficient way to "shuffle" a List?

Any help is greatly appreciated :)

Thank you

Answer

Aryabhatta picture Aryabhatta · Feb 20, 2010

Fisher-Yates Shuffle or as it is also known as, Knuth shuffle.