Re: array of array



Bob Bedford wrote:

> I've to save in an array of array some values.
>
> Problem: I don't know the size of the array before filling it.
>
> I'd like something like
>
> $bigarray = array():
>
> then runnig the code I must create dinamically (I don't know how
> many) few arrays in the bigarray; $bigarray["X"] = array():
> $bigarray["Y"] = array():
>
> then fill those arrays with few unknow number of values.
> array_push($bigarray["X"],$value1);
> array_push($bigarray["X"],$value2);
>
> array_push($bigarray["Y"],$value5);
> ...
> but array_push doesn't manage it.
>
> How to do so ?

$bigarray["X"][] = $value1;
$bigarray["X"][] = $value2;
....
$bigarray["Y"][] = $value5;

--
Kim André Akerø
- kimandre@xxxxxxxxxxxxxxxxxx
(remove NOSPAM to contact me directly)
.



Relevant Pages

  • Re: cloneNode() not getting script tag content
    ... the elements under the form tag. ... With the script tags I am filling out a javascript associative array: ...
    (comp.lang.javascript)
  • Re: valid VMA ranges and mincore()
    ... it appears to be filling in values of -1 into ... -1 from the system call and set errno to ENOMEM. ... Linux: http://linux.about.com/library/cmd/blcmdl2_mincore.htm ... - Filling in values of -1 into the array will confuse existing applications, ...
    (freebsd-hackers)
  • Array data after file close
    ... Apparently, when filling an array from a file, the array's data ceases to ... I was under the impression that DAwould continue to exist within this ...
    (microsoft.public.vb.general.discussion)
  • Re: Can i Box values in arrays
    ... values is Recordset. ... Its not filling the array. ... Prev by Date: ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Using GetDIBits is not loading all the picture in the array
    ... Correction - Noticed that the GetDIBits is only filling the first part ... The y variable refers to height index, ... when this is updated to the next count the array will load only few ...
    (comp.lang.basic.visual.misc)