fork download
  1. <?php
  2. function numberToText1($amount1){
  3. $remainder = ($amount1 % 100);
  4. if ($amount1==0) {
  5. $result[]=$amount1;
  6. }
  7. elseif (floor($amount1/100)>0){
  8. $result[]=((floor($amount1/100)*100));
  9. }
  10. elseif (($remainder>10) & ($remainder<20)){
  11. $result[]=($remainder);
  12. }
  13.  
  14.  
  15. return $result;
  16. }
  17. var_dump(numberToText1(115));
Success #stdin #stdout 0.01s 82560KB
stdin
Standard input is empty
stdout
array(1) {
  [0]=>
  float(100)
}