列表注意还原为空列表 摘要:解题思路:注意事项:参考代码:while True: a,b,c=map(int,input().split()) d=[a,b,c] xx=sorted(d) if xx[0…… 题解列表 2022年04月06日 0 点赞 0 评论 352 浏览 评分:0.0
分类讨论以及循环输入 摘要:解题思路:注意事项:参考代码:while True: a=int(input()) if a<=100 and a>=90: print('A') el…… 题解列表 2022年04月06日 0 点赞 0 评论 415 浏览 评分:2.0
字符串的循环输出以及注意换行 摘要:解题思路:注意事项:参考代码:while True: a=int(input()) b=' ' c='*' for i in range(1,a…… 题解列表 2022年04月06日 0 点赞 0 评论 440 浏览 评分:0.0
列表的循环输入,利用列表切片和求和 摘要:解题思路:注意事项:参考代码:while True: a=list(map(int,input().split())) a=a[1:] for i in a: xx=a…… 题解列表 2022年04月06日 0 点赞 0 评论 525 浏览 评分:0.0
注意换行和列表清空 摘要:解题思路:注意事项:参考代码:while True: a=list(map(int,input().split())) a=a[1:] b=sorted(a,reverse=True…… 题解列表 2022年04月06日 0 点赞 0 评论 418 浏览 评分:0.0
while循环的持续输入 摘要:解题思路:注意事项:参考代码:while True: a,b=map(int,input().split()) print(a+b)…… 题解列表 2022年04月06日 0 点赞 0 评论 376 浏览 评分:9.9
带限制条件的分组背包 摘要:```C++ #include #include /* 思路:首先尝试将问题简化,如果去掉等级这一限制,那么所有的装饰孔可以合并成一个体积为V的背包,对于下面m组t个物品,我们只选…… 题解列表 2022年04月06日 0 点赞 0 评论 634 浏览 评分:5.1
模拟双指针 (代码简洁) 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;#include<algorithm>int main(){ int a=0,b=9;/…… 题解列表 2022年04月06日 0 点赞 0 评论 345 浏览 评分:0.0
超简短代码 摘要:解题思路:注意事项:参考代码:while True: a,b=map(int,input().split()) print(a+b) print()…… 题解列表 2022年04月06日 0 点赞 0 评论 394 浏览 评分:0.0
题目化解+操作数函数+赋初值与输入输出解释 摘要:题目简化:1.对于n ,如果n是偶数,则除以2 ;如果n是奇数,乘以3再加1 。这会产生 从n到1的 操作次数。(如n=1时,操作次数为1 ,即 有1个数) 2.对于 每一对输入的整数i和j , 要…… 题解列表 2022年04月06日 0 点赞 0 评论 448 浏览 评分:9.9