Exemple #1
0
 public MathResult DoMath(double n1, double n2)
 {
     MathResult mr = new MathResult();
     mr.sum = n1 + n2;
     mr.difference = n1 - n2;
     mr.product = n1 * n2;
     mr.quotient = n1 / n2;
     return mr;
 }
Exemple #2
0
        public MathResult DoMath(double n1, double n2)
        {
            MathResult mr = new MathResult();

            mr.sum        = n1 + n2;
            mr.difference = n1 - n2;
            mr.product    = n1 * n2;
            mr.quotient   = n1 / n2;
            return(mr);
        }