Office and School Supplies

Sabtu, 07 November 2015

Contoh Array

Share it Please
#include <iostream.h>
#include <conio.h>

main () {
typedef int matrik22[2][2];                
matrik22 A,B,C;
int i,j,k;

//A
for(j=0;j<2;j++) {
    for(i=0;i<2;i++) {
     cout<<"Matrik A ["<<j<<"]["<<i<<"] : ";
     cin>>A[j][i];
    }
   }
cout<<endl;

//B
for(j=0;j<2;j++) {
    for(i=0;i<2;i++) {
     cout<<"Matrik B ["<<j<<"]["<<i<<"] : ";
     cin>>B[j][i];
    }
   }

//menampilkan array
for(j=0;j<2;j++) {
    for(i=0;i<2;j++) {
     C[j][i]=A[j][i]*B[j][i];
     }
    }

getch () ;
}

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

© 2013 Information Technology as The Key of Future. All rights resevered. Designed by Templateism