random numbers - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


random numbers

Homerun31Homerun31 Posts: 99Member
is there a way to make random numbers and you give the exact numbers that you want to be random. example:

i want 1 2 3 4 5 6 10 20 30 40 50 60 chosen randomly but they can only be those numbers


  • Johnny13Johnny13 Posts: 128Member
    if these numbers have no relation(can't be calculated),you can use an array..
    echo $num[rand(0,count($num)-1)];
Sign In or Register to comment.