public static void Main() { var db = SingletonDataContainer.Instance; Console.WriteLine(db.GetPopulation("ivan")); var db2 = SingletonDataContainer.Instance; var db3 = new SingletonDataContainer(); var db4 = SingletonDataContainer.Instance; }
public static void Main() { SingletonDataContainer db = SingletonDataContainer.Instance; Console.WriteLine(db.GetPopulation("Capital City")); SingletonDataContainer db1 = SingletonDataContainer.Instance; Console.WriteLine(db.GetPopulation("Pliska")); SingletonDataContainer db2 = SingletonDataContainer.Instance; Console.WriteLine(db.GetPopulation("London")); SingletonDataContainer db3 = SingletonDataContainer.Instance; Console.WriteLine(db.GetPopulation("Mumbai")); }