Array 2 Dimensi
Membuat Matrix
#include <iostream.h>
#include <conio.h>
main()
cout< }
cout<<"\nContoh Matrix"<<matrix;
for(x=0;x<=4;x++)
{
for(y=0;y<=4;y++)
{
cout< }
cout< }
getch();
}
Hasil Output
Membuat Matrix
#include <iostream.h>
#include <conio.h>
main()
{
int matrix[5][5];
int x,y;
for(x=0;x<=4;x++)
{
for(y=0;y<=4;y++)
{
cout<<"Masukkan angka baris ke- ";
cin>>matrix[x][y];
}
int matrix[5][5];
int x,y;
for(x=0;x<=4;x++)
{
for(y=0;y<=4;y++)
{
cout<<"Masukkan angka baris ke- ";
}
cout<
cout<<"\nContoh Matrix"<
{
for(y=0;y<=4;y++)
{
cout<
cout<
getch();
}
Hasil Output
0 Comment:
Post a Comment