hello, i am trying to modify a perl script but i really only know php lol
how would i go about on doing rand(10,19); on perl?
i tried all combinations i could think of but cant get it to work![]()
hello, i am trying to modify a perl script but i really only know php lol
how would i go about on doing rand(10,19); on perl?
i tried all combinations i could think of but cant get it to work![]()
Try:
Just find the range of the numbers (by subtracting), and add the minimum. In php:Code:print int(rand(9))+10;
It's the same basics.Code:echo rand(0, 9) + 10;
Range: 19-10 = 9
Minimum: 10
Jeremy | jfein.net
nicmo (03-31-2010)
clever lol, thanks mate.
No problem, glad to help.
It seems your topic is solved... Please set the status to resolved.. To do this:
Go to your first post ->
Edit your first post ->
Click "Go Advanced" ->
Then in the drop down next to the title, select "RESOLVED"
Jeremy | jfein.net
Bookmarks