#include<constrea.h>
#include<stdio.h>
void main(){
char nim[9][10],nama[30][10],jenkel[10][10];
int sem[9];
int i,jlh;
cout<<"masukkan jumlah data : ";cin>>jlh;
clrscr();
for(i=1; i<=jlh; i++)
{
clrscr();
cout<<"input data yang ke- "<<i<<endl;
cout<<"masukkan NIM : ";gets(nim[i]);
cout<<"masukkan nama : ";gets(nama[i]);
cout<<"masukkan jenkel : ";gets(jenkel[i]);
cout<<"masukkan semester : ";cin>>sem[i];
}
cout<<endl<<endl;
//menampilkan data
clrscr();
cout<<"---------------------------------------------------------------\n";
cout<<"| NIM | NAMA | JENKEL | SEMESTER |\n";
cout<<"---------------------------------------------------------------\n";
for(i=1; i<=jlh; i++)
{
gotoxy(1,4+i);cout<<"|";
gotoxy(5,4+i);cout<<nim[i];
gotoxy(18,4+i);cout<<"|";
gotoxy(20,4+i);cout<<nama[i];
gotoxy(33,4+i);cout<<"|";
gotoxy(35,4+i);cout<<jenkel[i];
gotoxy(50,4+i);cout<<"|";
gotoxy(55,4+i);cout<<sem[i]<<endl;
gotoxy(63,4+i);cout<<"|"<<endl;
}
cout<<"---------------------------------------------------------------\n";
gotoxy(48,5+i);cout<<"created by jerry";
getch();
}