Random playlist algorithm
问题 I need to create a list of numbers from a range (for example from x to y) in a random order so that every order has an equal chance. I need this for a music player I write in C#, to create play lists in a random order. Any ideas? Thanks. EDIT: I'm not interested in changing the original list, just pick up random indexes from a range in a random order so that every order has an equal chance. Here's what I've wrriten so far: public static IEnumerable<int> RandomIndexes(int count) { if (count >