Tugas 2

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

NAMA : M. Fauzan Eksando.

P
KELAS : Teknik Industri B-Sore
NIM : 230601061

 KONVERSI SUHU

print('==================================')
print('## Program Python Konversi Suhu ##')
print('==================================')
print()

C = int(input(' suhu celsius: '))

F = (9/5 * C) + 32
K = C + 273

print(C,'\n')
print(f'{C} °C =', F, chr(176),'F \n')
print(f'{C} °C =', K, chr(176),'K \n')
 MENGHITUNG LUAS & KELILING LINGKARAN

print('============================================')
print('## Menghitung Luas & Keliling Lingkungan ##')
print('============================================')
print()

D = float(input('massukan diameter : '))


pi=22/7
r= D/2
L= 22/7*r*r
K = 22/7*D*D

print(D, '\n')
print("Luas = 22/7", "*", round (r), "*", round(r),"\n")
print( 'Luas Lingkaran : ' , round (L),'\n')
print("Keliling = 22/7", "*", round (D), "*", round(D),"\n")
print('Keliling Lingkaran : ' ,round( K))

You might also like