static void Main(string[] args) { CarManager manager = new CarManager(); var car1 = manager.CreateCar(10, 20); var s1 = manager.GetSize(car1); System.Diagnostics.Debug.Assert(s1 == 20); var car2 = manager.CreateCar(30, 40); var s2 = manager.GetSize(car2); System.Diagnostics.Debug.Assert(s2 == 40); manager.RemoveCar(ref car1); System.Diagnostics.Debug.Assert(car1.ID == -1); s2 = manager.GetSize(car2); var car3 = manager.CreateCar(50, 60); var s3 = manager.GetSize(car3); System.Diagnostics.Debug.Assert(s3 == 60); }