Ejemplo n.º 1
0
        public void Test1()
        {
            string result = obj3.task3(8, '#');
            string otvet  = "\"";

            for (int i = 0; i < 8; i++)
            {
                otvet += '#';
            }
            otvet += "\"";
            Assert.AreEqual(otvet, result);
        }
Ejemplo n.º 2
0
        public void Execute(Lab3Calc Laba3)
        {
            int  A;
            char B;

            Console.WriteLine("Введите A");
            int.TryParse(Console.ReadLine(), out A);
            Console.WriteLine("Введите B");
            char.TryParse(Console.ReadLine(), out B);

            try
            {
                Console.WriteLine(Laba3.task3(A, B));
            }
            catch (ArgumentException e)
            {
                Console.WriteLine(e.Message);
            }
        }