AD (728x60)

Diberdayakan oleh Blogger.

Sabtu, 05 Maret 2016

Contoh Perulangan

Share & Comment
Assalamualikum w.w,
Berikut ini adalah salah satu contoh perulangan:

#include <iostream>

/* run this program using the console pauser or add your own getch, system("pause") or input loop */
using namespace std;
int main(int argc, char** argv) {
   
    int i,j,k;
   
   
    for(i=1;i<=6;i++){
        cout<<i;
        for(j=1;j<=i;j++){
            cout<<j;
           
        }
        for(k=i;k<6;k++){
            cout<<"*";
            }
        cout<<endl;
}
    return 0;
}
Gambar Program nya :
Gambar Ouput nya:

Semoga Bermanfaat ...
Wassalamualaikum w.w.

Tags:

Written by

We are Creative Blogger Theme Wavers which provides user friendly, effective and easy to use themes. Each support has free and providing HD support screen casting.

0 komentar:

Posting Komentar

 
Copyright © safirizky blogs | Designed by Templateism.com