#include
#include
#include
main()
{
int z;
typedef struct employee
{
char Nama[20];
char Nim[8];
char MK[20];
long SKS;
};
employee a[20];
cout<<"Masukkan jumlah data:";cin>>z;
for (int g=1; g<=z;g++)
{
cout<<"Input data ke"<< g;
cout<<'\n';
cout<<"Nama :";cin>>a[g].Nama;
cout<<"Nim :";cin>>a[g].Nim;
cout<<"MK :";cin>>a[g].MK;
cout<<"SKS :";cin>>a[g].SKS;
cout<<'\n';
}
cout<<"menampilkan nilai yg telah diinput"<< endl;// 1234567890123456789012345678901234567890123456789012345678901234567890
cout<<"==============================================================="<< endl;
cout<<"Nama Nim Mata Kuliah SKS"<< endl;
cout<<"==============================================================="<< endl;
for (int j=1; j<=z;j++)
{
cout<< setiosflags(ios::left)<< setw(25)<< a[j].Nama;
cout<< setiosflags(ios::left)<< setw(10)<< a[j].Nim;
cout<< setiosflags(ios::left)<< setw(25)<< a[j].MK;
cout<< setiosflags(ios::left)<< setw(3)<< a[j].SKS<< endl;
}cout<<"==============================================================="<< endl;
}