Thread: help for (for)
View Single Post
Old Mar 28th, 2008, 3:53 AM   #1
dark06
Newbie
 
Join Date: Mar 2008
Posts: 3
Rep Power: 0 dark06 is on a distinguished road
help for (for)

<?
$c = $_POST['col'];
$r = $_POST['rw'];
?>

<?
for($cvchk = 1; $cchk<= $c; $cchk ++)
{
echo $cchk."<br>";

for($rchk = 1; $rchk<= $r; $rchk ++)
{
echo $rchk." ";
}
}

?>

i don't know what is wrong with this one
i want the output to become this one

1 2 3 4
2 3 4 1
3 4 1 2
4 1 2 3

i really kinda new with this thanks a lot guys

guys can you help me out with this one..
dark06 is offline   Reply With Quote