<?php // your code goes here$myStr = '83-59- -520-1';$myArr = preg_split('/[\D]+/', $myStr);var_dump($myArr);
Standard input is empty
array(4) { [0]=> string(2) "83" [1]=> string(2) "59" [2]=> string(3) "520" [3]=> string(1) "1" }
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!