コード例 #1
0
        static void Main(string[] args)
        {
            //
            Country c1 = new Country("UAS", "North Americal", new List <string> {
                "Red", "White", "Blue"
            });
            Country c2 = new Country("UK", "Europe", new List <string> {
                "Red", "White", "Blue"
            });
            Country c3 = new Country("Nepal", "Asia", new List <string> {
                "Red", "Blue", "White"
            });
            Country c4 = new Country("Jamica", "Africa", new List <string> {
                "Black", "Yellow", "Green"
            });
            Country c5 = new Country("Japan", "Asia", new List <string> {
                "Red", "White"
            });
            List <Country> countries = new List <Country> {
                c1, c2, c3, c4, c5
            };

            CountryController countryController = new CountryController(countries);

            countryController.WelcomeAction();
        }
コード例 #2
0
        static void Main(string[] args)
        {
            Console.WriteLine("Hello World!");
            CountryController c = new CountryController();

            c.WelcomeAction();
        }
コード例 #3
0
        static void Main(string[] args)
        {
            CountryController cc = new CountryController();

            cc.WelcomeAction();

            Console.ReadKey();
        }
コード例 #4
0
        static void Main(string[] args)
        {
            CountryController cc = new CountryController();

            while (true)
            {
                cc.WelcomeAction();

                break;
            }
        }
コード例 #5
0
        static void Main(string[] args)
        {
            CountryController cc = new CountryController();

            cc.WelcomeAction();
            while (true)
            {
                Console.WriteLine();
                Console.WriteLine("Would you like to learn about another country?");
                string answer = Console.ReadLine().ToLower().Trim();
                if (answer == "y")
                {
                    Console.WriteLine();
                    cc.WelcomeAction();
                }
                else if (answer == "n")
                {
                    Console.WriteLine();
                    Console.WriteLine("Goodbye");
                    break;
                }
            }
        }
コード例 #6
0
        static void Main(string[] args)
        {
            CountryController myLiege = new CountryController();

            myLiege.WelcomeAction();
        }