Exemplo n.º 1
0
        public static void CheckGradus()
        {
            Shapes sectoin = new Section(X, Y);

            sectoin.DrawENG();
            Thread.Sleep(2000);
            SelectENG.NextChangeENG();
        }
Exemplo n.º 2
0
        public static void InitializingSquare()
        {
            Square square = new Square(A, B);

            square.DrawENG();
            Thread.Sleep(2000);
            SelectENG.NextChangeENG();
        }
Exemplo n.º 3
0
        public static void InitializingCircle()
        {
            Circle circle = new Circle(radiusCircle);

            Console.WriteLine("Area of a circle S = " + circle.FigureArea());
            Thread.Sleep(2000);
            SelectENG.NextChangeENG();
        }
Exemplo n.º 4
0
        public static void Trapezium()
        {
            Console.OutputEncoding = Encoding.UTF8;
            try
            {
                Console.WriteLine("Enter the value of points x1, y1: ");
                x1 = int.Parse(Console.ReadLine());
                y1 = int.Parse(Console.ReadLine());
                Console.WriteLine("Enter the value of points x2,y2: ");
                x2 = int.Parse(Console.ReadLine());
                y2 = int.Parse(Console.ReadLine());
                Console.WriteLine("Enter the value of points x3,y3: ");
                x3 = int.Parse(Console.ReadLine());
                y3 = int.Parse(Console.ReadLine());
                Console.WriteLine("Enter the value of points x4,y4: ");
                x4 = int.Parse(Console.ReadLine());
                y4 = int.Parse(Console.ReadLine());

                Trapezium trapezium = new Trapezium(x1, x2, x3, x4, y1, y2, y3, y4);

                if (trapezium.FigureArea() is 0)
                {
                    ExeptionFilter.ExeptionOutputENG();
                    ChangeTrapezium();
                }
                else
                {
                    trapezium.DrawENG();
                    SelectENG.NextChangeENG();
                }
            }
            catch
            {
                ExeptionFilter.ExeptionOutputENG();
                Trapezium();
            }
        }