Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #We hope that users of this script will not change the owner's name or declare themselves to be the owner
- #based on Article 40 paragraph (1) letter s of Law Number 28 of 2014 concerning Copyright ("Copyright Law")
- #This script was created without copying someone else's, please provide proof of license if you own the script!
- #//@AlfanNPstore.co // Thx For God // Thx For Python . Program sederhana v1.0.0.tokyo (T)KS01-tokyo
- #Module
- from time import sleep
- import sys
- import random
- import time
- #HEADER
- print(' Hello, We are From the TOKYO Group '.center(50,'—'))
- print('version : 1.0.0.tokyo | type : KS01-tokyo'.center(50))
- #\\Menu utama
- def home():
- print('\n')
- print(' Konversi Suhu '.center(50,'—'))
- print('celcius = C reamur = R Kelvin = K Farenheit = F'.center(50))
- print('—'*(50))
- print('| CELCIUS | REAMUR | KELVIN | FARENHEIT |')
- print(' 0. about '.center(50,'—'))
- tanya = input('input menu[C|R|K|F] - Out [X] \n»')
- if tanya == 'c' or tanya == 'C':
- tokyo_C()
- elif tanya == 'R' or tanya == 'r':
- tokyo_R()
- elif tanya == 'K' or tanya == 'k':
- tokyo_K()
- elif tanya == 'F' or tanya == 'f':
- tokyo_F()
- elif tanya == '0' or tanya == 'about':
- tokyo_about()
- elif tanya == 'x' or tanya == 'X':
- print('(Out) Sampai Jumpa Lagi :> ')
- sys.exit()
- else:
- tokyo_error()
- home()
- #AlfanNPstore.co
- #eceknya wm
- def tokyo_about():
- print('\n')
- print('—'*(35))
- print('| KELOMPOK : TOKYO |')
- print('—'*(35))
- print('| MARNI PANE SITORUS |[ANGGOTA]')
- print('| ALFAN NUGRAHA PANJAITAN|[ KETUA ]')
- print('| SRI MAY SILPI |[ANGGOTA]')
- print('| NURUL HIDAYANI |[ANGGOTA]')
- print('| RIFSKI ARDIANSYAH |[ANGGOTA]')
- print('—'*(36))
- tokyo_watermark()
- tokyo_quest()
- #MENU NEXT OR NO
- #\\AlfanNPstore.co
- def tokyo_quest():
- print('\n')
- go = input('[Y]HOME | [T]OUT » ')
- if go == 'y' or go == 'Y':
- home()
- elif go == 't' or go == 'T':
- print('(OUT) Sampai Jumpa Lagi :> ')
- sys.exit()
- else:
- tokyo_quest()
- #Teks berjalan
- #\\Kelompok Tokyo
- def tokyo_watermark():
- eceknya = 'Projek simple yang dibuat oleh,-\n'
- thx = 'kelompok TOKYO di Kelas IF-C sore '
- for c in eceknya+thx:
- sys.stdout.write(c)
- sys.stdout.flush()
- time.sleep(random.random()*0.1)
- #\\Error teks
- def tokyo_error():
- error = '[TOKYO] Menu NotFound - TryAgain !'
- for c in error:
- sys.stdout.write(c)
- sys.stdout.flush()
- time.sleep(random.random()*0.1)
- ###MENU
- #\\disini menu konversi celcius
- def tokyo_C():
- print('\n')
- print(' Konversi Celcius '.center(50,'—'))
- print(' 1. Reamur 2. Kelvin 3. Farenheit '.center(50))
- tc = input('Konversi Ke [1|2|3] - Back [B]\n»»» ')
- print('-'*(50))
- if tc == '1':
- tanya1()
- elif tc == '2':
- tanya2()
- elif tc == '3':
- tanya3()
- elif tc == 'B' or tc == 'b':
- home()
- else:
- tokyo_error()
- tokyo_C()
- #\\disini menu konversi reamur
- def tokyo_R():
- print('\n')
- print(' Konversi Reamur '.center(50,'—'))
- print(' 1. Celcius 2. Kelvin 3. Faren#heit '.center(50))
- tr = input('Konversi Ke [1|2|3] - Back [B]\n»»» ')
- print('-'*(50))
- if tr == '1':
- tanya4()
- elif tr == '2':
- tanya5()
- elif tr == '3':
- tanya6()
- elif tr == 'B' or tr == 'b':
- home()
- else:
- tokyo_error()
- tokyo_R()
- #\\disini menu konversi kelvin
- def tokyo_K():
- print('\n')
- print(' Konversi Kelvin '.center(50,'—'))
- print(' 1. Reamur 2. Celcius 3. Farenheit '.center(50))
- tc = input('Konversi Ke [1|2|3] - Back [B]\n»»» ')
- print('-'*(50))
- if tc == '1':
- tanya8()
- elif tc == '2':
- tanya7()
- elif tc == '3':
- tanya9()
- elif tc == 'B' or tc == 'b':
- home()
- else:
- tokyo_error()
- tokyo_K()
- #\\disini menu konversi farenheit
- def tokyo_F():
- print('\n')
- print(' Konversi Farenheit '.center(50,'—'))
- print(' 1. Reamur 2. Kelvin 3. Celcius '.center(50))
- tc = input('Konversi Ke [1|2|3] - Back [B]\n»»» ')
- print('-'*(50))
- if tc == '1':
- tanya10()
- elif tc == '2':
- tanya12()
- elif tc == '3':
- tanya11()
- elif tc == 'B' or tc == 'b':
- home()
- else:
- tokyo_error()
- tokyo_F()
- #\\Konversi celcius
- #\Celcius - reamur
- def tanya1():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_celcius1()
- elif xv == 'C' or xv == 'c':
- txv = input('Celcius Konversi [K|F] » ')
- if txv == 'K' or txv == 'k':
- tokyo_celcius2()
- elif txv == 'F' or txv == 'f':
- tokyo_celcius3()
- else:
- tokyo_error()
- print('\n')
- tanya1()
- def tokyo_celcius1():
- print('\n')
- print('[+] Celcius - Reamur')
- celcius1 = float(input('Masukkan Suhu[°C]\t : '))
- reamur1 = 4/5*celcius1
- print('Hasil[°R]\t\t : {:.1f}'.format(reamur1))
- tokyo_quest()
- #Celcius - Kelvin
- def tanya2():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_celcius2()
- elif xv == 'C' or xv == 'c':
- txv = input('Celcius Konversi [C|F] » ')
- if txv == 'C' or txv == 'c':
- tokyo_celcius1()
- elif txv == 'F' or txv == 'f':
- tokyo_celcius3()
- else:
- tokyo_error()
- print('\n')
- tanya2()
- def tokyo_celcius2():
- print('\n')
- print(' Celcius - Kelvin '.center(50))
- celcius2 = float(input('Masukkan Suhu[°C] : '))
- kelvin1 = 273+celcius2
- print('Hasil[°K] : {:.1f}'.format(kelvin1))
- tokyo_quest()
- #\Celcius - Farenheit
- def tanya3():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_celcius3()
- elif xv == 'C' or xv == 'c':
- txv = input('Celcius Konversi [K|R] » ')
- if txv == 'K' or txv == 'k':
- tokyo_celcius2()
- elif txv == 'R' or txv == 'r':
- tokyo_celcius1()
- else:
- tokyo_error()
- print('\n')
- tanya3()
- def tokyo_celcius3():
- print('\n')
- print(' Celcius - Farenheit '.center(50))
- celcius3 = float(input('Masukkan Suhu[°C] : '))
- farenheit1 = 9/5*celcius3+32
- print('Hasil[°F] : {:.1f}'.format(farenheit1))
- tokyo_quest()
- #\\konversi reamur
- #\reamur - celcius
- def tanya4():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_reamur1()
- elif xv == 'C' or xv == 'c':
- txv = input('Reamur Konversi [K|F] » ')
- if txv == 'K' or txv == 'k':
- tokyo_reamur2()
- elif txv == 'F' or txv == 'f':
- tokyo_reamur3()
- else:
- tokyo_error()
- print('\n')
- tanya4()
- def tokyo_reamur1():
- print('\n')
- print('[+] Reamur - Celcius')
- reamur1 = float(input('Masukkan Suhu[°R]\t : '))
- celcius4 = 5/4*reamur1
- print('Hasil[°C]\t\t : {:.1f}'.format(celcius4))
- tokyo_quest()
- #\reamur - kelvin
- def tanya5():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_reamur2()
- elif xv == 'C' or xv == 'c':
- txv = input('Reamur Konversi [C|F] » ')
- if txv == 'C' or txv == 'c':
- tokyo_reamur1()
- elif txv == 'F' or txv == 'f':
- tokyo_reamur3()
- else:
- tokyo_error()
- print('\n')
- tanya5()
- def tokyo_reamur2():
- print('\n')
- print('[+] Reamur - Kelvin ')
- reamur2 = float(input('Masukkan Suhu[°R]\t : '))
- kelvin2 = (5/4*reamur2)+273
- print('Hasil[°K]\t\t : {:.1f}'.format(kelvin2))
- tokyo_quest()
- #\reamur - farenheit
- def tanya6():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_reamur3()
- elif xv == 'C' or xv == 'c':
- txv = input('Reamur Konversi [K|C] » ')
- if txv == 'K' or txv == 'k':
- tokyo_reamur1()
- elif txv == 'C' or txv == 'c':
- tokyo_reamur1()
- else:
- tokyo_error()
- print('\n')
- tanya6()
- def tokyo_reamur3():
- print('\n')
- print('[+] Reamur - Farenheit')
- reamur3 = float(input('Masukkan Suhu[°R]\t : '))
- fahrenheit2 = (9/4*reamur3)+32
- print('Hasil[°F]\t\t : {:.1f}'.format(fahrenheit2))
- tokyo_quest()
- #\\konversi kelvin
- #\kelvin - celcius
- def tanya7():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_kelvin1()
- elif xv == 'C' or xv == 'c':
- txv = input('Kelvin Konversi [R|F] » ')
- if txv == 'R' or txv == 'r':
- tokyo_kelvin2()
- elif txv == 'F' or txv == 'f':
- tokyo_kelvin3()
- else:
- tokyo_error()
- print('\n')
- tanya7()
- def tokyo_kelvin1():
- print('\n')
- print('[+] Kelvin - Celcius')
- kelvin3 = float(input('Masukkan Suhu[°K]\t : '))
- celcius5 = kelvin3-273.15
- print('Hasil[°C]\t\t : {:.1f}'.format(celcius5))
- tokyo_quest()
- #\kelvin - reamur
- def tanya8():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_kelvin2()
- elif xv == 'C' or xv == 'c':
- txv = input('Kelvin Konversi [C|F] » ')
- if txv == 'C' or txv == 'c':
- tokyo_kelvin1()
- elif txv == 'F' or txv == 'f':
- tokyo_kelvin3()
- else:
- tokyo_error()
- print('\n')
- tanya8()
- def tokyo_kelvin2():
- print('\n')
- print('[+] Kelvin - Reamur')
- kelvin4 = float(input('Masukkan Suhu[°K]\t : '))
- reamur4 = 4/5*(kelvin4-273)
- print('Hasil[°R]\t\t : {:.1f}'.format(reamur4))
- tokyo_quest()
- #\kelvin - fahrenheit
- def tanya9():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_kelvin3()
- elif xv == 'C' or xv == 'c':
- txv = input('Kelvin Konversi [R|C] » ')
- if txv == 'R' or txv == 'r':
- tokyo_kelvin1()
- elif txv == 'C' or txv == 'c':
- tokyo_kelvin2()
- else:
- tokyo_error()
- print('\n')
- tanya9()
- def tokyo_kelvin3():
- print('\n')
- print('[+] Kelvin - Fahrenheit')
- kelvin5 = float(input('Masukkan Suhu[°K]\t : '))
- fahrenheit3 = ((kelvin5-273.15)*9/5)+32
- print('Hasil[°F]\t\t : {:.1f}'.format(fahrenheit3))
- tokyo_quest()
- #\\konversi fahrenheit
- #\fahrenheit - reamur
- def tanya10():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_fahrenheit1()
- elif xv == 'C' or xv == 'c':
- txv = input('Fahrenheit Konversi [C|K] » ')
- if txv == 'C' or txv == 'c':
- tokyo_fahrenheit2()
- elif txv == 'F' or txv == 'f':
- tokyo_fahrenheit3()
- else:
- tokyo_error()
- print('\n')
- tanya10()
- def tokyo_fahrenheit1():
- print('\n')
- print('[+] Fahrenheit - Reamur')
- fahrenheit4 = float(input('Masukkan Suhu[°F]\t : '))
- reamur6 = 4/9*(fahrenheit4-32)
- print('Hasil[°R]\t\t : {:.1f}'.format(reamur6))
- tokyo_quest()
- #\fahrenheit - celcius
- def tanya11():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_fahrenheit2()
- elif xv == 'C' or xv == 'c':
- txv = input('Fahrenheit Konversi [R|K] » ')
- if txv == 'R' or txv == 'r':
- tokyo_fahrenheit1()
- elif txv == 'K' or txv == 'k':
- tokyo_fahrenheit3()
- else:
- tokyo_error()
- print('\n')
- tanya11()
- def tokyo_fahrenheit2():
- print('\n')
- print('[+] Fahrenheit - Celcius')
- fahrenheit5 = float(input('Masukkan Suhu[°F]\t : '))
- celcius6 = (fahrenheit5-32)*5/9
- print('Hasil[°C]\t\t : {:.1f}'.format(celcius6))
- tokyo_quest()
- #\fahrenheit - kelvin
- def tanya12():
- xv = input('[N]Next | [C]Change » ')
- if xv == 'N' or xv == 'n':
- tokyo_fahrenheit3()
- elif xv == 'C' or xv == 'c':
- txv = input('Fahrenheit Konversi [C|R] » ')
- if txv == 'C' or txv == 'c':
- tokyo_fahrenheit2()
- elif txv == 'R' or txv == 'r':
- tokyo_fahrenheit1()
- else:
- tokyo_error()
- print('\n')
- tanya12()
- def tokyo_fahrenheit3():
- print('\n')
- print('[+] Fahrenheit - Kelvin')
- fahrenheit6 = float(input('Masukkan Suhu[°F]\t : '))
- kelvin6 = (fahrenheit6-32)*5/9+273
- print('Hasil[°K]\t\t : {:.1f}'.format(kelvin6))
- tokyo_quest()
- #\\memanggil fungsi menu home
- home()
Advertisement
Add Comment
Please, Sign In to add comment