Write a php code which could be used to generate random
numbers between 1 - 100 and display them on the screen.
Answer Posted / solutio magister
<?php
$n=10;//number_of_numbers_required_to_display
for($i=0;$i<$n;$i++)
{
echo rand(1,100)."<br>";
}
?>
| Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
Explain the ternary conditional operator in php?
What library is used for pdf in php?
When sessions ends?
List some features of php that are deprecated in php7?
What is regular expression in php?
Why do we need abstract class in php?
What is the meaning of "enctype= multipart/form-data" ?
Explain what does the unset() function means?
Is laravel better than codeigniter?
What are PHP Magic Methods/Functions. List them.
What is the difference between php4 and php5?
What is namespace and use in php?
How to access a global variable inside a function?
Does php has a future?
Tell me what does the array operator '===' means?