This example simulates a game in which the user spins a wheel with random speed. The wheel rotates slower and slower until it stops. Then the user can spin it again, from the previous stop position, as shown in the following diagram:
Let's proceed to the first part of code of the Main method in the Program class:
CircularLinkedList<string> categories = new CircularLinkedList<string>(); categories.AddLast("Sport"); categories.AddLast("Culture"); categories.AddLast("History"); categories.AddLast("Geography"); categories.AddLast("People"); categories.AddLast("Technology"); categories.AddLast("Nature"); categories.AddLast("Science"); ...