Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- uses crt;
- var
- hasil:string;
- n:integer;
- begin
- clrscr;
- write('nilai: ');readln(n);
- if n in[1..100] then
- begin
- if n in[1..20] then
- writeln('E')
- else if n in[21..40] then
- hasil:='D'
- else if n in[41..60] then
- hasil:='C'
- else if n in[61..80] then
- hasil:='B'
- else if n in[81-100] then
- hasil:='A'
- else
- hasil:=' Nilai anda tidak diantara 0-100';
- end;
- writeln('Kategori nilai anda: ',hasil);
- readln;
- end.
Advertisement
Add Comment
Please, Sign In to add comment