program coba;
uses crt ;
label
atas ;
var
pilihan :
byte;
nama,nim,kelas,asal
: string ;
lagi : char ;
begin
clrscr;
atas :
writeln(' MENU ');
writeln('1.
BACA DATA ');
writeln('2.
CETAK DATA ');
writeln('3.
UBAH DATA ');
writeln('4.
HAPUS DATA ');
writeln('5.
KELUAR PROGRAM');
write('PILIH
MENU: ');
readln
(pilihan);
Case Pilihan
of
1 : Begin
writeln('INPUT DATA ANDA');
writeln('---------------');
write ('Nama :' );
readln (nama) ;
write ('NIM :' );
readln (nim) ;
write ('Kelas :' );
readln (kelas) ;
write ('Asal Kota :' );
readln (asal) ;
writeln('---------------');
writeln('Terima Kasih');
writeln('SELANJUTNYA SILAKAN
CETAK DATA');
End;
2 : Begin
writeln('CETAK DATA ANDA');
writeln('---------------');
writeln ('Nama :',nama );
Writeln ('NIM :',nim );
writeln ('Kelas :',kelas );
writeln ('Asal Kota :',asal );
writeln('---------------');
writeln('Terima Kasih');
writeln('SELAMAT BERAKTIVITAS');
End;
3 : Begin
writeln('UBAH DATA ANDA');
writeln('---------------');
write ('Nama :' );
readln (nama) ;
write ('NIM :' );
readln (nim) ;
write ('Kelas :' );
readln (kelas) ;
write ('Asal Kota :' );
readln (asal) ;
writeln('---------------');
writeln('Terima Kasih');
writeln('SELANJUTNYA SILAKAN
CETAK DATA');
End;
4 : Begin
writeln('HAPUS DATA ANDA');
writeln('---------------');
writeln('DATA ANDA DIHAPUS');
End;
5 : Begin
writeln ('Keluar Program Pilih
T')
End;
Else
Begin
Writeln ('Pilihannya hanya 1, 2,
3, 4, 5 !!!' );
Writeln ('silahkan ulangi lagi'
);
End ;
End ;
write ('ULANGI [Y/T] : ');
readln (lagi);
if (lagi = 'Y') then
goto atas;
readln;
end.
|