Ejemplo n.º 1
0
        public static void Main(string[] args)
        {
            Console.ForegroundColor = ConsoleColor.Yellow;

            Console.WriteLine("BNU CO453 Applications Programming 2020-2021!");
            Console.WriteLine();
            Console.Beep();

            string [] choices = { " Distance Converter", " BMI Calculator", " Student Grades",
                                  " Social Network",     " RPG Game" };

            int choice = ConsoleHelper.SelectChoice(choices);

            if (choice == 1)
            {
                DistanceConverter converter = new DistanceConverter();
                converter.Run();
            }
            else if (choice == 2)
            {
                BMI calculator = new App02.BMI();
                calculator.Run();
            }
            else if (choice == 3)
            {
                StudentMarks grader = new StudentMarks();
                grader.Run();
            }
            else if (choice == 4)
            {
                SocialNetworkMain social = new SocialNetworkMain();
                social.Run();
            }
        }
Ejemplo n.º 2
0
        public static void Main()
        {
            Console.ForegroundColor = ConsoleColor.Yellow;

            Console.WriteLine("BNU CO453 Applications Programming 2020-2021!");
            Console.WriteLine();
            Console.Beep();

            Console.WriteLine("1. Distance converter");
            Console.WriteLine("2. BMI Calculator");
            Console.WriteLine("3. Student Grades");
            Console.WriteLine("4. Student Grades");
            Console.WriteLine("5. Student Grades");

            Console.WriteLine(0);

            Console.WriteLine("Select an applocation  ");
            string choice = Console.ReadLine();

            if (choice == "1")
            {
                DistanceConverter converter = new DistanceConverter();
                converter.MilesToFeet();
                converter.MetresToMiles();
                converter.KilometresToMiles();
                converter.MilesToFeet2();
                converter.MetresToMiles2();
                converter.KilometresToMiles2();
                converter.MetresTofeet();
                converter.FeetToMetres();
            }
            else if (choice == "2")
            {
            }
            else if (choice == "3")
            {
                StudentMarks students = new StudentMarks();
                students.Run();
            }
            else if (choice == "4")
            {
                Socialnet social = new Socialnet();
                social.Run();
            }
            else if (choice == "5")
            {
                StudentMarks students = new StudentMarks();
                students.Run();
            }


            // BMI calculator = new BMI();
            // BMI();
            //     Console.ReadLine();
        }
Ejemplo n.º 3
0
        public static void ChoseApplication(int AppNumber)
        {
            switch (AppNumber)
            {
            case APP01:
                ConsoleHelper.PrintString("Distance Converter", true);

                //Create an object
                DistanceConverter converter = new DistanceConverter();
                converter.RunDistanceConverter();

                break;

            case APP02:
                ConsoleHelper.PrintString("BMI Converter", true);
                ConsoleHelper.PrintString(bmi.GetDescription(), false);
                bmi.RunBmiConverter();
                break;

            case APP03:
                ConsoleHelper.PrintString("Student Marks", true);
                StudentMarks students = new StudentMarks();
                students.Run();
                break;

            case APP04:
                SocialNetwork social = new SocialNetwork();
                social.Run();

                break;

            case APP05:

            default:
                break;
            }
        }