fork(1) download
  1. <?php
  2.  
  3. echo preg_replace('/0$/', '', '07.10');
  4. echo "\n";
  5.  
  6. echo preg_replace('/(\..*)0$/', '$1', '07.10');
  7. echo "\n";
  8.  
  9. echo preg_replace('/(\..*)0$/', '$1', '0710');
  10. echo "\n";
Success #stdin #stdout 0.01s 82944KB
stdin
Standard input is empty
stdout
07.1
07.1
0710