what method is used to generate a random number?

Answers were Sorted based on User's Feedback



what method is used to generate a random number?..

Answer / lakhan lal

use rand() or mt_rand()

example:rand() or rand(20,30);

Is This Answer Correct ?    7 Yes 1 No

what method is used to generate a random number?..

Answer / mahidhar

using rand() function we generate the random numbers.

example : $num="12345678";
$result=rand($num);

the $result gives the random numbers.

Is This Answer Correct ?    7 Yes 4 No

what method is used to generate a random number?..

Answer / senthilkumar g

using srand();
it will generate the randam numbers

Is This Answer Correct ?    3 Yes 0 No

what method is used to generate a random number?..

Answer / sunil kumar

<?php
echo(4,900);//depend upon ur choice
?>

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More PHP Interview Questions

What are the different types of PHP arrays?

0 Answers  


What is json php?

0 Answers  


What is php default argument?

0 Answers  


How to redirect https to http url and vice versa in .htaccess?

0 Answers  


hi to all i am fresher in php and want to learn php and want a fresher job in php. how to total time i expend to learn php and what is freshers salary.

9 Answers  






What type of operation is needed when passing values through a form or an url?

0 Answers  


Is php 5 still supported?

0 Answers  


Can you use php and javascript together?

0 Answers  


Is php used for frontend or backend?

0 Answers  


Can we embedded directly PHP code into XHTML document? State Whether True or False?

0 Answers  


Which software is used to run php programs?

0 Answers  


What is super keyword in php?

0 Answers  


Categories