Пример #1
0
        /// <summary>
        /// Exercice 3.2 de la série d'exercices progressifs de Jerome Conus
        /// </summary>
        public static void IndividuBis()
        {
            Individu firstIndividu  = new Individu("Bejo", "Bérénice", 1976);
            Individu secondIndividu = new Individu("Dujardin", "Jean", 1972);

            Console.WriteLine(firstIndividu.presenter());
            Console.WriteLine(secondIndividu.presenter());

            secondIndividu.Nom = "Dupotager";
            firstIndividu.Nom  = "Hazanavicious";

            Console.WriteLine("Nous changeons de noms.");

            Console.WriteLine(firstIndividu.presenter());
            Console.WriteLine(secondIndividu.presenter());
        }
Пример #2
0
        /// <summary>
        /// Exercice 3.3 de la série d'exercices progressifs de Jerome Conus
        /// </summary>
        public static void IndividuBisRepetita()
        {
            Individu firstIndividu  = new Individu("Bejo", "Bérénice", 1976);
            Individu secondIndividu = new Individu("Dujardin", "Jean", 1972);

            Console.WriteLine(firstIndividu.presenter());
            Console.WriteLine(secondIndividu.presenter());

            secondIndividu.Prenom        = "";
            secondIndividu.Nom           = "";
            firstIndividu.AnneeNaissance = 2300;

            Console.WriteLine("Nous changeons de noms.");

            Console.WriteLine(firstIndividu.presenter());
            Console.WriteLine(secondIndividu.presenter());

            Application.Younger(firstIndividu, secondIndividu);
        }
Пример #3
0
        /// <summary>
        /// Exercice 3.5 de la série d'exercices progressifs de Jerome Conus
        /// </summary>
        public static void IndividuBientotFini()
        {
            Individu firstIndividu  = new Individu("Dujardin", "Jean", 1972);
            Individu secondIndividu = new Individu("Bejo", "Bérénice", 1976);
            Individu thirdIndividu  = new Individu("William", "Arthur Michael", 2018);
            Individu fourthIndividu = new Individu("Komarova", "Alexa", 2051);

            Console.WriteLine(firstIndividu.presenter());
            Console.WriteLine(secondIndividu.presenter());
            Console.WriteLine(thirdIndividu.presenter());
            Console.WriteLine(fourthIndividu.presenter());
        }