题解列表

筛选

2788: 晶晶赴约会

摘要:解题思路:注意事项:参考代码:import sys a = int(input())if a < 1 or a > 7:    sys.exit()           #退出程序elif a != ……

同因查找(还行)

摘要:解题思路:注意事项:参考代码:for i in range(10,1000):    if i%2==0 and i%3==0 and i%7==0:        print(i)    ……

求偶数和(还行的解法)

摘要:解题思路:注意事项:参考代码:n=int(input())sn=0lit=list(map(int,input().split()))for i in lit:    if i%2==0:      ……

2786: 判断能否被3、5、7整除

摘要:解题思路:不用循环,只用条件判断语句注意事项:参考代码:a = int(input())if a % 3 == 0 and a % 5 == 0 and a % 7 == 0:    print(&#……

有点繁琐,不过有注释

摘要:参考代码:ISBN=input()x=ISBN.replace(&#39;-&#39;,&#39;&#39;) #把ISBN号的-去除X=[] #存储ISBN号尾不为X的ISBN数字a="" #存储I……

2782: 整数大小比较

摘要:while 1:    try:        while 1:            x,y = map(int,input().strip().split())            if (x ……

2781: 奇偶ASCII值判断

摘要:解题思路:注意事项:参考代码:while 1:    try:        a = str(input())        if ord(a) % 2 == 0:            print(……