Write a php code which could be used to generate random
numbers between 1 - 100 and display them on the screen.
Answer Posted / yatin
<?php
$n=100; //number_of_numbers_required_to_display
for($i=0;$i<$n;$i++)
{
$num=rand(1,100);
echo $num."<br>";}
?>
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
How do I run a php program in dreamweaver?
Which function gives us the number of affected entries by a query?
What is the sign to start variables in PHP?
What is the differences between $a != $B and $a !== $B?
What is binary safe function in php?
Explain what are the three classes of errors that can occur in php?
What is the method to register a variable into a session?
How to close a session properly?
What beforeFilter() is used?
What is dao in php?
Explain how does one prevent the following warning ‘warning: cannot modify header information – headers already sent' and why does it occur in the first place?
How be the result set of mysql handled in php?
What is session and why do we use it?
What are sql injections, how do you prevent them and what are the best practices?
What is if isset ($_ post submit )) in php?