Exemplo n.º 1
0
        public string DispenseAmount(int amount)
        {
            DispenseFactory dispFactory = new DispenseFactory();

            dispFactory.DistributeMoney(amount);
            return(ReturnAmount == 0 ? "Thank you please visit again" : "please enter proper input");
        }
Exemplo n.º 2
0
 public FiveHundred(int amount)
 {
     ReturnAmount = CalculateLogic(amount, 500);
     if (ReturnAmount > 0)
     {
         DispenseFactory dispenseFactory = new DispenseFactory();
         dispenseFactory.DistributeMoney(ReturnAmount);
     }
 }
Exemplo n.º 3
0
 public Thousand(int amount)
 {
     ReturnAmount = CalculateLogic(amount, 1000);
     if (ReturnAmount > 0)
     {
         DispenseFactory dispenseFactory = new DispenseFactory();
         dispenseFactory.DistributeMoney(ReturnAmount);
     }
 }