+ 2

array_rand

Can someone, please, help me to explain how does "array_rand" works (PHP)?. I have tried some examples from the Internet but the Code Playground says that there are errors in the code. I really need help.

13th Apr 2017, 12:18 AM
JoĂŁo Samuel
JoĂŁo Samuel - avatar
1 Answer
+ 2
The array_rand() function returns a random key from an array
13th Apr 2017, 3:44 AM
Naveen DA
Naveen DA - avatar