编写题解 1001: [编程入门]第一个HelloWorld程序(Python) 摘要:解题思路:只要用Python中print函数就行 注意事项:别把*的数量搞错了参考代码:print("**************************")print("Hello World!")…… 题解列表 2022年06月10日 0 点赞 0 评论 365 浏览 评分:0.0
1022: [编程入门]筛选N以内的素数 摘要:a=int(input()) ls=[2] for i in range(3,a+1,2): flag=0 for j in ls: if i%j==0: …… 题解列表 2022年06月10日 0 点赞 0 评论 279 浏览 评分:0.0
1022: [编程入门]筛选N以内的素数 摘要:a=int(input()) ls=[2] for i in range(3,a+1,2): flag=0 for j in ls: if i%j==0: …… 题解列表 2022年06月10日 0 点赞 0 评论 358 浏览 评分:0.0
基础解法(有手就行) 摘要:解题思路:python学一个星期就会了注意事项:无参考代码:def copy(b,a): c=0 for i in a: c+=1 if c>=b: print(i,end…… 题解列表 2022年06月09日 0 点赞 0 评论 482 浏览 评分:9.9
python直观解法 摘要:解题思路:注意事项:参考代码:cow_age = [1, 0, 0]n = int(input())for year in range(2, n+1): temp = cow_age[2] …… 题解列表 2022年06月09日 0 点赞 0 评论 329 浏览 评分:0.0
核电站python直观解法 摘要:解题思路:后续添加注意事项:后续添加参考代码:def f(m1, n1): if m1 == 0: return 1 sum_m = 1 for n_f in rang…… 题解列表 2022年06月08日 0 点赞 0 评论 372 浏览 评分:0.0
python直观解法 摘要:解题思路:主要用到一个index()函数,用于确定某个存在于列表中的元素的索引注意事项:无参考代码:results_s = []while True: try: st = inpu…… 题解列表 2022年06月08日 0 点赞 0 评论 321 浏览 评分:0.0
Python题解阶乘求和 摘要:解题思路:注意事项:参考代码:s,k=1,1n=int(input())for i in range(2,n+1): k*=i s+=kprint(s)…… 题解列表 2022年06月07日 0 点赞 0 评论 388 浏览 评分:0.0
Python题解字符串分类统计 摘要:解题思路:注意事项:参考代码:zm,sz,kg,qt=0,0,0,0s=input()for c in s: if c>='a' and c<='z' or c>…… 题解列表 2022年06月07日 0 点赞 0 评论 416 浏览 评分:6.0
Python题解最大公约数与最小公倍数 摘要:解题思路:辗转相除注意事项:参考代码:a,b=map(int,input().split())s=a*bwhile a%b: a,b=b,a%bprint(b,s//b)…… 题解列表 2022年06月07日 0 点赞 8 评论 1464 浏览 评分:9.2