fork download
  1. <?php
  2. $string = "4113.52318N";
  3. $result = preg_match_all('/^(\d{2})([\d.]+)/', $string, $matches);
  4. $partOne = $matches[1][0];
  5. $partTwo = $matches[2][0];
  6.  
  7. echo "$partOne \n$partTwo";
  8.  
  9.  
Success #stdin #stdout 0.03s 52480KB
stdin
Standard input is empty
stdout
41 
13.52318