|
Posted by Darko on 11/05/07 16:19
On Nov 5, 3:44 pm, "Bob Bedford" <b...@bedford.com> wrote:
> Hello,
>
> I've an array of array(1,2,3,4). I'd like to retrieve the values in 3 and 4
> giving the values 1 and 2. How can I do that, how to search in an array of
> array ? in short, how to write the findvalue function ?
>
> $list = array();
> array_push($list,array(1,1,'x','x');
> array_push($list,array(1,2,'x','y');
> array_push($list,array(2,1,'y','x');
> array_push($list,array(2,2,'y','y');
>
> $result = array();
> $result = findvalue(1,2); //should return 'x','y'
>
> function findvalue($a,$b){
> //return the array of values...
>
> }
>
> Thanks for helping.
>
> Bob
What have you tried already?
We won't do your homeworks ;-)
[Back to original message]
|