Contoh Program Pascal Perhitungan Ipk

Contoh Program Pascal  Perhitungan Ipk
uses wincrt;
var  a,b,c : string;
x : integer;
d:char;        
Grade : string;
begin
repeat
clrscr;
write('masukan nama siswa :');readln(a);
write('masukan angkatan   :');readln(b);
write('masukan kelas      :');readln(c);
write ('Inputkan Nilai Angka : '); readln(x);
case x of
0..44 : Grade :='E';
45..54 : Grade :='D';
55..69 : Grade :='C';
70..84 : Grade :='B';
85..100 : Grade :='A';
else
grade :='Tidak ada Nilai';
end;
writeln('==============...HASIL....=============');
writeln('Nama           :',a);
writeln('angkatan       :',b);
writeln('kelas          :',c);
writeln ('IPK        :',Grade);
writeln('=======================================');  readln;
clrscr;
write('apakah anda ingin mengitung lagi?[y/t]');readln(d);
until upcase(d)<>'Y';
end.

0 komentar:

Post a Comment

Copyright © 2014 Dunia Naeta All Right Reserved