<?php $tests = [ 'Paid a bill £0.90', 'Paid a bill £100', 'Paid a bill £100.10', 'Paid a bill £1000' ]; foreach ($tests as $test) { var_dump(sscanf($test, '%*[^£]£%f')[0]); echo "\n"; }
You have javascript disabled. You will not be able to edit any code.