标题:Python小白|分享一点代码,想提高效率
只看楼主
harryhe2022
Rank: 1
等 级:新手上路
帖 子:2
专家分:0
注 册:2018-9-1
 问题点数:0 回复次数:1 
Python小白|分享一点代码,想提高效率
#!/user/desktop/py
# -*- coding: utf-8   -*-

# Filename : degree.py
# created by : Harry He
# transfer degrees
import easygui as gui
while(1):
    set
    choices = gui.choicebox(msg="What do you want to convert?",    title="Degrees Converter", choices=("F to C","C to F"))
    if choices == "F2C":
        f = float(gui.enterbox(msg="What is the degrees in Fahrenheit degrees?", title="Degrees Converter"))
        c = (f-32)/1.8
        gui.msgbox(msg=int(c), title="Degrees Converter")
    else:
        c = float(gui.enterbox(msg="What is the degrees in Centigrade degrees?", title="Degrees Converter"))
        f = c*1.8+32
        gui.msgbox(msg=int(f), title="Degrees Converter")
#contents:
#emial : harryhe2022@
#phonenumber : 15911185189
                                                '''copyright JUST KIDDING'''
                                                '''TAKE IT AND USE IT FOR YOURSELF'''
搜索更多相关主题的帖子: Python 分享 效率 gui title 
2018-09-01 11:58
harryhe2022
Rank: 1
等 级:新手上路
帖 子:2
专家分:0
注 册:2018-9-1
得分:0 
附上函数模组
2018-09-01 11:58



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-489565-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.076870 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved