首页    新闻    小组    威客    人才    下载    博客    代码贴    在线编程    论坛
代码贴随便看看全站
age = int(input("Please input your age:\n"))
if age < 2:
    print("原来你是个婴儿!!")
elif age < 4:
    print("原来你是蹒跚学步!!")
elif age < 20:
    print("原来你是青少年!!")
elif age < 65:
    print("原来你是成年人!!")
else:
    print("原来你是老年人!!")
阅读全部 | GunL 贴于 2021年7月10日 15:59     hide bbsi
def chick():
    s=input("请输入坐标: x , y ")
    x,y=tuple(map(float,s.split(",")))
    #print('x=',x, "y=",y)
    for i in [(2,2),(-2,2),(-2,-2),(2,-2)]:
        if (x-i[0])**2+(y-i[1])**2<=1:
            return (f"在圆心{i}的圆内")
    return "不在圆内"
print(chick())
阅读全部 | song0758 贴于 2021年7月9日 15:06     hide bbsi
def make_car(manufacturer,model,**type_info):
    """创建一个字典,其中包含我们知道的有关用户的一切"""
    profile = {}
    profile['manufacturer'] = manufacturer
    profile['model'] = model
    for key,value in type_info.items():
        profile[key] = value
    return profile
    
car = make_car('subaru','outback',color = 'blue',tow_package = True)
print(car)
阅读全部 | GunL 贴于 2021年7月6日 21:35     hide bbsi
def make_car(manufacturer,model,**type_info):
    """创建一个字典,其中包含我们知道的有关用户的一切"""
    profile = {}
    profile['manufacturer'] = manufacturer
    profile['model'] = model
    for key,value in type_info.items():
        profile[key] = value
    return profile
    
car = make_car('subaru','outback',color = 'blue',tow_package = True)
print(car)
阅读全部 | GunL 贴于 2021年7月6日 21:35     hide bbsi
magicians = ['ergou','qiqi','shitou']
great_magicians = []

def make_great(magicians,great_magicians):
    while magicians:
        magician = magicians.pop()
        great_magician = 'the Great' + magician
        great_magicians.append(great_magician)
        
def show_magicianslis(great_magicians):
    for name in great_magicians:
        print(name)
......................
阅读全部 | GunL 贴于 2021年7月6日 21:33     hide bbsi
magicians = ['ergou','qiqi','shitou']
great_magicians = []

def make_great(magicians,great_magicians):
    while magicians:
        magician = magicians.pop()
        great_magician = 'the Great' + magician
        great_magicians.append(great_magician)
        
def show_magicianslis(great_magicians):
    for name in great_magicians:
        print(name)
......................
阅读全部 | GunL 贴于 2021年7月6日 21:32     hide bbsi
def milk_album(name,album_name,number=''):
    album = {'name':name,'album_name':album_name}
    return album
while True:
    print("(enter 'q' at any time to quit)")
    name = input("请输入歌手名:")
    if name == 'q':
        break
    album_name = input("请输入专辑名:")
    if album_name == 'q':
        break 
    print(milk_album(name,album_name))
阅读全部 | GunL 贴于 2021年7月6日 21:29     hide bbsi
places = {}
polling_active = True
while polling_active:
    name = input("\n What is your name? ")
    response = input("If you could visit one place in the world, where would you go?")
    places[name] = response
    repeat = input("Would you like to let another person respond? (yes/ no) ")
    if repeat == 'no':
         polling_active = False
 
print("\n--- Poll Results ---")
 
......................
阅读全部 | GunL 贴于 2021年7月6日 21:20     hide bbsi
var bus_station=["A","B","C","D","E"];

var arr_name_id=[];
var arr_name=[];
var arr_from_address=[];
var arr_from_time=[];

var arr_to_time=[];
var arr_to_address=[];

function up_bus(id,name,address,time){
arr_name_id.push(id);
......................
阅读全部 | dwzh 贴于 2021年7月6日 09:56     hide bbsi
function QQSpeed_Common() {
    this.版本 = "2021/06/01"
    this.UI = Object()
    this.批量关闭 = function () {
        Api.Shell("taskkill /f /t /im GameApp.exe", 0)
        Api.Shell("taskkill /f /t /im QQSpeed_loader.exe", 0)
    }
    this.清理进程 = function () {
        var WMI = GetObject("WinMgmts:")
        var wind = ['"IIPSHostApp.exe"', '"QQSpeedChatBrowser.exe"', '"QQSpeedCefProcess.exe"']
        var n = WMI.ExecQuery('select * from win32_process where name=' + wind.join('or name=')).Count
        for (var i = 0; i < wind.length; i++) {
......................
阅读全部 | angelfly 贴于 2021年6月1日 12:07     hide bbsi
上一页 77 78 79 80 81 82 83 84 85 86 下一页