can you solve this problem with regex ?

From: Date: Mon, 17 Jan 2005 10:03:38 +0000
Subject: can you solve this problem with regex ?
Groups: php.general 
Request: Send a blank email to php-general+get-206526@lists.php.net to get a copy of this message
Hello ! My user can input values like this : 15.2 10-5 10 0 0x5 005 00 to be clear, i must extract two values from each line, each value is between 1 and 20 and seaparated with a non numeric caracter, so with lines 1,2,3 and 4 i will get : Array([0]=>15, [1]=>2); Array([0]=>10, [1]=>5); Array([0]=>10, [1]=>0); Array([0]=>0, [1]=>5); and for other lines i will label them as erronus entries... how can i do it intelligently :)

« previous php.general (#206526) next »