uses crt;
var
i,n:byte;
no:array[1..100] of string;
nim_12012739:array[1..100] of string;
nama:array[1..100] of string;
alamat:array[1..100] of string;
umur:array[1..100] of integer;
jawab:string;
label tampil, keluar, input;
begin
textbackground(blue);
clrscr;
//inputan
textcolor(yellow);
input:
writeln('*=======================*');
writeln('| BIODATA MAHASISWA |');
writeln('*=======================*');
writeln;
write('Masukan Jumlah data = '); readln(n);
writeln;
for i:=1 to n do
begin
write('NO = ');
readln(no[i]);
write('NIM = ');
readln(nim_12012739[i]);
write('NAMA = ');
readln(nama[i]);
write('ALAMAT = ');
readln(alamat[i]);
write('UMUR = ');
readln(umur[i]);
writeln;
end;
writeln;
//cara menampilkan (output)
write('apakah anda ingin menampilkan data sebelumnya ? (Y/T) ');
readln(jawab);
if (jawab='y') or (jawab='Y') then
begin
writeln;
for i:=1 to n do
begin
writeln('Biodata Mahasiswa ke = ',no[i]);
writeln('Nim = ',nim_12012739[i]);
writeln('Nama = ',nama[i]);
writeln('Alamat = ',alamat[i]);
writeln('Umur = ',umur[i]);
writeln;
end;
readln;
end
else goto tampil;
tampil:
write('Anda ingin keluar dari sistem ? (Y/T) ');
readln(jawab);
if (jawab='y') or (jawab='Y') then
goto keluar
else
goto input;
keluar:
end.
var
i,n:byte;
no:array[1..100] of string;
nim_12012739:array[1..100] of string;
nama:array[1..100] of string;
alamat:array[1..100] of string;
umur:array[1..100] of integer;
jawab:string;
label tampil, keluar, input;
begin
textbackground(blue);
clrscr;
//inputan
textcolor(yellow);
input:
writeln('*=======================*');
writeln('| BIODATA MAHASISWA |');
writeln('*=======================*');
writeln;
write('Masukan Jumlah data = '); readln(n);
writeln;
for i:=1 to n do
begin
write('NO = ');
readln(no[i]);
write('NIM = ');
readln(nim_12012739[i]);
write('NAMA = ');
readln(nama[i]);
write('ALAMAT = ');
readln(alamat[i]);
write('UMUR = ');
readln(umur[i]);
writeln;
end;
writeln;
//cara menampilkan (output)
write('apakah anda ingin menampilkan data sebelumnya ? (Y/T) ');
readln(jawab);
if (jawab='y') or (jawab='Y') then
begin
writeln;
for i:=1 to n do
begin
writeln('Biodata Mahasiswa ke = ',no[i]);
writeln('Nim = ',nim_12012739[i]);
writeln('Nama = ',nama[i]);
writeln('Alamat = ',alamat[i]);
writeln('Umur = ',umur[i]);
writeln;
end;
readln;
end
else goto tampil;
tampil:
write('Anda ingin keluar dari sistem ? (Y/T) ');
readln(jawab);
if (jawab='y') or (jawab='Y') then
goto keluar
else
goto input;
keluar:
end.