using System.Collections.Generic;
public static void Main()
Random random = new Random();
Movies MulhollandDrive = new Movies("Mulholland Dr.", "Naomi Watts", "Laura Harring", "Justin Theroux");
Movies ShawshankRedemption = new Movies("The Shawshank Redemption", "Tim Robbins", "Morgan Freeman", "Some Other Yutzes");
Movies GreenMile = new Movies("The Green Mile", "Tom Hanks", "Michael Clark Duncan", "Barry Pepper");
Movies AmericanBeauty = new Movies("American Beauty", "Kevin Spacey", "Annette Bening", "Chris Cooper");
Movies AmericanHistoryX = new Movies("American History X", "Edward Norton", "Edward Furlong", "Stacy Keach");
Movies GlenGarryGlenRoss = new Movies("Glen Garry Glen Ross", "Al Pacino", "Alec Baldwin", "Jack Lemmon");
Dictionary<int, Movies> movies = new Dictionary<int, Movies>();
movies.Add(1, MulhollandDrive);
movies.Add(2, ShawshankRedemption);
movies.Add(3, GreenMile);
movies.Add(4, AmericanBeauty);
movies.Add(5, AmericanHistoryX);
movies[6] = GlenGarryGlenRoss;
Console.WriteLine(movies[random.Next(1,6)].Name);
foreach (var movie in movies)
Console.WriteLine(movie.Key + ": " + movie.Value.Name + " featuring " + movie.Value.Actor1 + " - " + movie.Value.Actor2 + " - " + movie.Value.Actor3);
public string Name { get; set; }
public string Actor1 { get; set; }
public string Actor2 { get; set; }
public string Actor3 { get; set; }
public Movies(string name, string actor1, string actor2, string actor3)