Exemplo n.º 1
0
 public void Task7799Test()
 {
     Assert.AreEqual(34.671920, Lab02.Task7799(5, 45), 0.0001);
     Assert.AreEqual(61972.336135, Lab02.Task7799(7297, 30), 0.0001);
     Assert.AreEqual(0, Lab02.Task7799(10, 90), 0.0001);
     Assert.AreEqual(0, Lab02.Task7799(7, 91), 0.0001);
     Assert.AreEqual(0, Lab02.Task7799(9, 100), 0.0001);
 }
Exemplo n.º 2
0
 static void Step7799()
 {
     Console.WriteLine();
     Console.WriteLine("7799");
     int[]    in7799mass = { 5, 7297, 10, 7, 9, 0 };
     int[]    in7799a    = { 45, 30, 90, 91, 100, 30 };
     double[] outs7799   = { 34.671920, 61972.336135, 0, 0, 0, 0 };
     for (int i = 0; i < in7799mass.Length; i++)
     {
         try
         {
             double result = Lab02.Task7799(in7799mass[i], in7799a[i]);
             Console.WriteLine("{0:F6} ({1:F6})", result, outs7799[i]);
         }
         catch (Exception e)
         {
             Console.WriteLine(e.Message);
         }
     }
 }
Exemplo n.º 3
0
 public void Task7799Assertion()
 {
     Lab02.Task7799(0, 30);
 }