除的类

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace jj4
{
   public class OperationDiv:Operation
    {
       public override double GetResult()
       {
            if(NumberB==0)
            {
                Console.WriteLine("不能为0");
            }
            double result = NumberA / NumberB;
               return result;
       }
    }
}
原文地址:https://www.cnblogs.com/nancheng/p/6691602.html