# Untitled

unknown
python
2 years ago
2.4 kB
0
Indexable
Never
```from os import system
from time import sleep
import os
system('clear')
system('clear')
x = input('''
KALKULATOR KONVERSI SUHU
1. CELCIUS ke REAMUR.
2. CELCIUS ke FAHRENHEIT.
3. CELCIUS ke KELVIN.
4. exit
=>> ''')
if x == '1':
reamur()
elif x == '2':
fahrenheit()
elif x == '3':
kelvin()
else:
system('clear')
print('TERIMA KASIH TELAH MENGGUNAKAN KALKULATOR INI \n\n Author : Ben')
def reamur():
system('clear')
print('Konversi Suhu Celcius ke Reamur\n')
c = int(input('Suhu Celcius : '))
result = 4 * c / 5
print('')
print('='*50)
print('                 HASIL')
print('='*50)
print('\nCelcius ke Reamur :', result)
print('')
print('='*50)
sleep(4)
x = input("\nAPAKAH KAMU INGIN MENGKONVERSI SUHU LAGI? [Y/N] : ")
if x == 'y' or x == 'Y':
else:
system('clear')
print('TERIMA KASIH TELAH MENGGUNAKAN KALKULATOR INI')
def fahrenheit():
system('clear')
print('Konversi Suhu Celcius ke Fahrenheit\n')
c = int(input("Suhu Celcius : "))
result = 9 * c / 5 + 32
print('')
print('='*50)
print('                 HASIL')
print('='*50)
print('\nCelcius ke Fahrenheit :', result)
print('')
print('='*50)
sleep(4)
x = input("\nAPAKAH KAMU INGIN MENGKONVERSI SUHU LAGI? [Y/N] : ")
if x == 'y' or x == 'Y':
else:
system('clear')
print('TERIMA KASIH TELAH MENGGUNAKAN KALKULATOR INI')
def kelvin():
system('clear')
print('Konversi Suhu Celcius ke Kelvin\n')
c = int(input('Suhu Celcius : '))
result = c + 273
print('')
print('='*50)
print('                 HASIL')
print('='*50)
print('\nCelcius ke Kelvin :', result)
print('')
print('='*50)
sleep(4)
x = input("\nAPAKAH KAMU INGIN MENGKONVERSI SUHU LAGI? [Y/N] : ")
if x == 'y' or x == 'Y':