题解列表
编写题解 1005: [编程入门]温度转换
摘要:解题思路:1.获取输入的华氏温度2.进行换算3.输出摄氏温度注意事项:公式为 c=5(F-32)/9‘()’可千万不要少打了哦参考代码:print('c=%.2f'%(5*(int(i……
暴力解法(凑字数。。。。。。。
摘要:解题思路:注意事项:参考代码:def shu(gewei,ci): if ci==1: return gewei else: return gewei*10*……
题解 | 3008: 买笔(简单易懂)
摘要:## 代码
```python
# 方法1
x = int(input())
pen_4 = int(x/4)
surplus = x%4
if(surplus == 3):
……
1062: 二级C语言-公约公倍 辗转相除法
摘要:解题思路:数学题,把公式带入。注意事项:参考代码:def gcd(x, y): m = max(x, y) n = min(x, y) while m % n: m, n = ……
1042: [编程入门]电报加密 简单的凯撒密码
摘要:解题思路:一看就是凯撒密码,循环替换就正确。注意事项:参考代码:x=input()s=""for i in x: if i>="a" and i<="z" or i>="A" and i<="Z"……
1016: [编程入门]水仙花数判断 稍稍复杂的循环判断
摘要:解题思路:就是简单循环判断题的加强版,设置范围,然后循环就好了。注意事项:参考代码:for i in range(100,1000): string=str(i) a=string[0] ……
暴力解法(凑字数。。。。。。。
摘要:解题思路:注意事项:参考代码:n=list(input())m=n.copy()n.reverse()c=m+nfor i in c: print(i,end='')……
直接用python内置函数
摘要:解题思路:注意事项:参考代码:import mathfor i in range(1,40): if math.gcd(i,40)==1: print('%d/40'……