Re: [PHP4BETA] no reverse fetch of arrays is BAD!

From: Date: Wed, 23 Feb 2000 12:42:01 +0000
Subject: Re: [PHP4BETA] no reverse fetch of arrays is BAD!
References: 1 2 3 4 5  Groups: php.version4 
Request: Send a blank email to php-version4+get-10715@lists.php.net to get a copy of this message
At 12:18 PM +0500 2000-02-23, Faisal Nasim wrote:
: : But, there is a major diff b/w perl and php: : : : : perl: $x[10] = "test"; // size of @x is 11 : : perl: $x[10] = "test"; // size of $x is 1 : : : : Which creates a new question: : : : : Is there a way to detect the upper bound of an array? : : And the lower bound too, of course... key ( $x ) returned the lower bound..... The definition for key(): key -- Fetch a key from an **associative** array Which caused me to skip it while checking the array functions! Can anybody change/fix that?
You might be better off just understanding that all arrays in PHP are associative. Or do you have a counter-example? -- Paul DuBois, paul@snake.net

« previous php.version4 (#10715) next »