PROGRAM Daftar_Mahasiswa;
Uses crt;
Const jml = 50;
Type nm = array[1..50] of string;
npm = array[1..50] of
char;
jk = array[1..50] of string;
var nama: nm;
nomor: npm;
jenis: jk;
a: byte;
begin
writeln(‘Memasukkan data-data mahasiswa’);
for a := 1 to jml do
begin
clrscr;
write(‘nama mahasiswa = ‘);readln(nama [a]);
write(‘npm mahasiswa = ‘);readln(nomor [a]);
write(‘jenis kelamin mahasiswa = ‘);readln(jenis [a]);
end;
{Mencetak Nama, NPM, dan Jenis Kelamin Mahasiswa}
Clrscr;
Writeln(‘-----------------------------------------------------------------------------------------------‘);
Writeln(‘|No.| Nama | NPM | JK
|’);
Writeln(‘-----------------------------------------------------------------------------------------------‘);
For a := 1 to jml do
begin
write(a);
write(nama [a]);
write(nomor [a]);
writeln(jenis [a]);
end;
writeln(‘------------------------------------------------------------------------------------------------‘);
readln;
end.
Tidak ada komentar:
Posting Komentar