HN-Community
[HELP] PHP Segitiga Angka - Printable Version

+- HN-Community (https://hacker-newbie.org)
+-- Forum: Miscellaneous (https://hacker-newbie.org/forum-86.html)
+--- Forum: Coding/Programing (https://hacker-newbie.org/forum-19.html)
+---- Forum: Web Programing (https://hacker-newbie.org/forum-38.html)
+---- Thread: [HELP] PHP Segitiga Angka (/thread-15612.html)



[HELP] PHP Segitiga Angka - ./tempatsampah - 11-25-2012

Assalamualaikum,
maaf mas kalau mengganggu.
mohon bantuan kalau Bingung agan agan tau sourcecode php ini :
Quote:1 3 5 7 9
3 5 7 9
5 7 9
7 9
9

10
8 10
6 8 10
4 6 8 10
2 4 6 8 10

menggunakan perulangan. Cheer


RE: [HELP] PHP Segitiga Angka - toro - 11-26-2012

<html>
<head></head>
<body>
<?
for ($i=1;$i<=9;$i=$i+2)
{
for ($j=$i;$j<=9;$j=$j+2)

{echo $j ." ";}
echo " ". "<br>";
}
?>
<br><br>
<?
for ($x=10;$x>1;$x=$x-2)
{
for ($y=$x;$y<=10;$y=$y+2)

{echo $y ." ";}
echo " ". "<br>";
}

?>
</body>
</html>

gak nolak cendol nya GantengGantengGanteng


RE: [HELP] PHP Segitiga Angka - arjuna - 11-26-2012

(11-26-2012, 01:21 AM)toro Wrote: <html>
<head></head>
<body>
<?
for ($i=1;$i<=9;$i=$i+2)
{
for ($j=$i;$j<=9;$j=$j+2)

{echo $j ." ";}
echo " ". "<br>";
}
?>
<br><br>
<?
for ($x=10;$x>1;$x=$x-2)
{
for ($y=$x;$y<=10;$y=$y+2)

{echo $y ." ";}
echo " ". "<br>";
}

?>
</body>
</html>

gak nolak cendol nya GantengGantengGanteng

Ane Check Dlo ya Bang HuwaaHuwaaHuwaa


RE: [HELP] PHP Segitiga Angka - toro - 11-27-2012

silahkan om ..
udah syaa cek sih sebenernya ..
CapekCapekCapek