program Project2;
{$APPTYPE CONSOLE}
uses
SysUtils;
var
r,t:integer;
l_lingkaran,v_tabung,v_kerucut:real;
begin
writeln('NAMA : AZIZUN NURRAHMAN');
writeln('NIM : 114224008');
writeln('=================================');
writeln('Program Menghitung Luas Lingkaran');
writeln('=================================');
write('Masukkan jari-jari = ');readln(r);
l_lingkaran:=3.14*r;
writeln('Luas Lingkaran = ',l_lingkaran:5:2);
writeln('---------------------------------');
writeln(' ');
writeln('================================');
writeln('Program Menghitung Volume Tabung');
writeln('================================');
write('Masukkan jari-jari = ');readln(r);
write('Masukkan tinggi = ');readln(t);
v_tabung:=3.14*r*r*t;
writeln('Volume Tabung = ',v_tabung:5:2);
writeln('---------------------------------');
writeln(' ');
writeln('=================================');
writeln('Program Menghitung Volume Kerucut');
writeln('=================================');
write('Masukkan jari-jari = ');readln(r);
write('Masukkan tinggi = ');readln(t);
v_kerucut:=0.5*3.14*r*t*r;
writeln('Volume Kerucut = ',v_kerucut:6:2);
readln;
{ TODO -oUser -cConsole Main : Insert code here }
end.
0 komentar:
Posting Komentar