自己写的,一定还有改进的地方,希望大家能指教,谢谢 摘要:解题思路:1.因为没有给具体的循环数量,需要根据b(空瓶子)数量而定,所以用do-while循环,先进入循环再cin>>b。2.每次喝下的空瓶子都还可以兑换饮料,因此无法判断循环次数,内循环也要用wh…… 题解列表 2024年03月17日 0 点赞 0 评论 271 浏览 评分:0.0
题解 1332: 津津的储蓄计划 摘要:解题思路:注意事项:参考代码:list1 = [] # 每月预算 for i in range(12): list1.extend(map(int, input().split()))…… 题解列表 2024年03月17日 0 点赞 0 评论 318 浏览 评分:0.0
约瑟夫的环 摘要:解题思路:注意事项:参考代码:import java.util.Scanner;public class wc {static Scanner sc=new Scanner(System.in);pu…… 题解列表 2024年03月17日 0 点赞 0 评论 311 浏览 评分:0.0
与指定数字相同的数的个数 摘要:解题思路:注意事项:参考代码:s=0a=list(map(int,input().split()))b=list(map(int,input().split()))for i in b: if …… 题解列表 2024年03月17日 0 点赞 0 评论 331 浏览 评分:0.0
C++两个函数求阶乘和x的平方,并通过主函数调用; 摘要:解题思路:注意事项:注意返回值为double类型参考代码:#include<iostream>#include<math.h>#include<iomanip>using namespace std;…… 题解列表 2024年03月17日 0 点赞 0 评论 356 浏览 评分:0.0
汽水瓶(python代码) 摘要:解题思路:注意事项:参考代码while True: n=int(input()) if n==0: break c=0 while n>=3: c=…… 题解列表 2024年03月17日 0 点赞 0 评论 279 浏览 评分:0.0
python选择排序 摘要:解题思路:注意事项:参考代码:a=list(map(int,input().split()))a.sort()for i in a: print(i)…… 题解列表 2024年03月17日 0 点赞 0 评论 250 浏览 评分:0.0
继续畅通工程 摘要:解题思路:最小生成树,如果道路是好的就提前连上且不用成本注意事项:参考代码:#include<bits/stdc++.h> using namespace std; int f[1000]; s…… 题解列表 2024年03月17日 0 点赞 0 评论 240 浏览 评分:0.0
直接解方程组 摘要:解题思路:注意事项:参考代码:x, a, y, b = map(int, input().split())m = b*y - a*xn = b- ares= m / nprint('%.2f&…… 题解列表 2024年03月17日 1 点赞 0 评论 516 浏览 评分:0.0
注意‘'x"要大写 摘要:解题思路:注意事项:参考代码:#include<stdio.h>void main(){ int h,l,i,z,y; int d;const int n;const int j;int *p=&j;…… 题解列表 2024年03月17日 0 点赞 0 评论 373 浏览 评分:0.0