Python编写简单易懂 包含知识点 markdown编写 摘要:``` str1=input() # 字符串的输入 flag=len(str1) # 字符串的长度 for i in str1 : a=str1.find(i) …… 题解列表 2023年07月12日 0 点赞 0 评论 433 浏览 评分:9.9
python 知识点:字符统计 简单易懂 摘要:解题思路:学习python第一天注意事项: python的在线编译器用不了参考代码:# 字符串的统计 str.count('字符串') 输出为int类型的个数str=input()a0…… 题解列表 2023年07月11日 0 点赞 1 评论 344 浏览 评分:4.7
题解 1001: [编程入门]第一个HelloWorld程序(仅需一行) 摘要:解题思路:在Python中print打印结束后会自动换行(\n),因此只需写三次print即可。其次在Python中可以使用“字符串” * 次数,来表达重复的“字符串”。还有(\n)也是换行的意思。注…… 题解列表 2023年07月10日 1 点赞 0 评论 229 浏览 评分:0.0
1002: [编程入门]三个数最大值 (python代码) 摘要:方法一 a, b, c = map(int, input().strip().split()) sum=[a, b, c] sum.sort() print(sum[2]) …… 题解列表 2023年07月09日 0 点赞 0 评论 464 浏览 评分:0.0
[python] 1001: [编程入门]第一个HelloWorld程序 摘要:方法一: print("**************************") print("Hello World!") print("**********************…… 题解列表 2023年07月09日 0 点赞 0 评论 290 浏览 评分:0.0
1000: [竞赛入门]简单的a+b (python代码) 摘要: while True: #while True 语句中一定要有结束该循环的break语句,否则会一直循环下去的 try: #Python 中,用try except语句块捕获…… 题解列表 2023年07月09日 3 点赞 0 评论 816 浏览 评分:8.0
反差法求解猴子吃桃问题——Python 摘要:解题思路:注意事项:参考代码:def caculate_peach_number(n): left_peaches = 1 day = n while day > 1: …… 题解列表 2023年07月08日 0 点赞 0 评论 316 浏览 评分:9.9
满分dfs(python) 摘要:解题思路:注意事项:参考代码:import functools n,m = map(int, input().split()) @functools.lru_cache(None) def df…… 题解列表 2023年07月07日 0 点赞 0 评论 239 浏览 评分:0.0
很简单的python代码 摘要:解题思路:注意事项:参考代码:for i in range(2,1000): total_sum = 0 array1 = list(str(i)) for digit in arr…… 题解列表 2023年07月05日 0 点赞 0 评论 394 浏览 评分:9.9
汽水题:较为标准的Python解法,参考了ChatGpt。 摘要:解题思路:注意事项:参考代码:def calculate_max_sodas(n): if n < 2: return 0 total_sodas = 0 remain…… 题解列表 2023年06月24日 0 点赞 0 评论 287 浏览 评分:9.9