Contoh tampilan
1
12
123
1234
12345
Program :
for(i=1;i<=5;i++)
{
for(a=1;a<=x;a++)
{
cout<<<"\n";
}
Tampilan
54321
4321
321
21
1
Programnya : for(i=5;i>=1;i--)
{
for(a=i;a>=1;a--)
{
cout<<<"\n"; }
0 komentar:
Posting Komentar