uses crt:
var
l1,l2,r : real:
a,t,pil : integer:
label exit mulai :
begin
mulai: writeln('Program');
writeln('1.Luas Lingkaran');
writeln('2.Luas Segitiga');
writeln('3.Keluar');
write('Masukan Pilihan = '); readln(pil);
case pil of
1: begin
writeln;
writeln('Luas Lingkaran');
write('Nilai Jari-Jari = '); readln(r);
l1:= 3.14*r*r;
write('Luas Lingkaran = ',l1:0:1);
readln;
end;
2: begin
writeln;
writeln('Luas Segitiga');
write('Nilai alas = '); readln(a);
write('Nilai Tinggi = '); readln(t);
l2:= a*t/2;
write('Luas Segitiga = ', l2:0:1);
readln;
end;
3: goto exit ;
else
writeln('Wooy Pilihan Lu Salah !!!'):
writeln('Ulangi Lagi');
writeln:
goto mulai:
end:
exit :
end.
JANGAN LUPA FOLLOW BLOG ANE sebagai imbalannya :p
0 komentar:
Posting Komentar