Write a PHP code to print following number pattern:
123
456
789
Answer Posted / sam
<?php
$num = "";
for($i = 1; $i<=9; $i++ )
{
if($i%3 == 1)
{
echo "<br />";
}
echo $i;
}
?>
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
Is php a middleware?
How many open modes available when a file open in PHP?
What is boolean in php?
What are the common uses of php?
What is csrf token and how it works?
What does the scope of variables mean?
What is a string in r?
What is difference between put and post method in http?
Is age interval or ordinal?
What is a session in php?
Tell me how is it possible to parse a configuration file?
How can we enable error reporting in php?
What is regular expression in php?
Is php 5.6 secure?
How can you declare the array in php?