random RSS

Follow our random RSS feed for all blog posts regarding anything random. Thanks for reading and we hope you enjoyed your visit. If you're looking for more articles use our search above or visit The Programmer blog for the latest and greatest.

c#, list, random

Randomizing a list<T> can be done using the Random and a simple LINQ query. Check out our card shuffling example below: Randomizing a list of objects Given a Card class public class Card { public string Name { get; set; } public int Value { get; set; } } Initialize a new list of cards var cards = new List<Card>()...

Read more