I have this:
$array = array(1 => array('min' => 0, 'max' => 0.5, 'value'=>12.5),
2 => array('min' => 0.5, 'max' => 1, 'value'=>13.5),
3 => array('min' => 1, 'max' => 1.5, 'value'=>15.5),
4 => array('min' => 1.5, 'max' => 2, 'value'=>18.5));
Then I have the variable (which of course is dynamic)
$number= 1.1;
How would I do to get the value 15.5 given that $number
is between 1
and 1.5
?