uses crt;
b,c: string;
d,e,f,g: integer;
h:char;
end;
var
mhs : array[1..40] of a;
i,n,tot1,tot2 : integer;
ip:real;
begin
clrscr;
write('Nama : Zakky Aulia');
writeln;
write('Nomor Bp : 1110453027');
writeln;
write('Jurusan : Sistem Komputer');
writeln;writeln;
tot1:=0;
tot2:=0;
write ('Banyak Mata Kuliah :
');readln(n);
for i:=1 to n do
begin
write('Kode Mata Kuliah : ');
readln(mhs[i].b);
write('Nama Mata Kuliah : ');
readln(mhs[i].c);
write('Nilai Angka : ');
readln(mhs[i].d);
if mhs[i].d <= 41 then begin
mhs[i].h :='E';
mhs[i].e:=0 end
else
if mhs[i].d <= 55 then begin
mhs[i].h :='D';
mhs[i].e:=1 end
else
if mhs[i].d <= 65 then begin
mhs[i].h :='C';
mhs[i].e:=2 end
else
if mhs[i].d <= 79 then begin
mhs[i].h :='B';
mhs[i].e:=3 end
else begin mhs[i].h := 'A';
mhs[i].e:=4; end;
write('Banyak SKS : ');
readln(mhs[i].f);
tot1:=tot1+mhs[i].f;
mhs[i].g:=mhs[i].e*mhs[i].f;
tot2:=tot2+mhs[i].g;
ip:=tot2/tot1;
writeln;
end;
clrscr;
write('Nama : Zakky Aulia');
writeln;
write('Nomor BP : 1110453027');
writeln;
write('Jurusan : Sistem Komputer');
writeln;
writeln('______________________________________________________
');
writeln('No| Kode | Mata kuliah |
Angka | Huruf | SKS | Total');
writeln('______________________________________________________
');
for i:= 1 to n do
begin
write(i:2,mhs[i].b:5,
mhs[i].c:15, mhs[i].d:7, mhs[i].h: 7,
mhs[i].f: (7), mhs[i].g: 9 );
writeln;
end;
gotoxy(1,n+9);writeln('Total SKS
: ',tot1);
writeln;
writeln('IP : ',ip:2:0);
readln;
end.
Input Untuk Tampilan Data Mahasiswa
Tampilan Output
0 komentar:
Posting Komentar