题解列表

筛选

津津的储蓄计划

摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){    int money=0,month=1,ys,count=0;    for(int i=1;i<13;i……

编写题解 2794: 求平均年龄

摘要:解题思路:首先使用 Scanner 类获取输入的数据。接下来,使用 for 循环遍历每个学生的年龄,将其加到年龄总和变量 sum 中。计算平均年龄,将年龄总和除以学生人数,需要将其转换为 double……

大整数除法java

摘要:解题思路:注意事项:参考代码:import java.math.BigDecimal;import java.util.Scanner;public class Main {    public st……

题目 1210: 小明A+B

摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;struct B{ int a1; int a2; };int main(){ in……

这题明明很简单,你知道你为啥做不对吗?

摘要:小编刚刚一看到这个题目的时候,感觉这个题目不是很简单吗? 但是每次提交都是显示格式错误 我顿时迷糊了 不过我立马又读了一变题目 and you must note that there is ……

1072: 汽水瓶

摘要:解题思路:对数数据一次次-3,直到不符合条件跳出第二层循环为止注意事项:n -= 3;要放在if (n == 2)sum++;后面注意顺序参考代码:#include <iostream>using n……

1299: 零花钱

摘要:```cpp #include using namespace std; struct lin { int a,b; }s[30]; int cmp(const void *x,……

使用库函数math

摘要:解题思路:注意事项:pow函数只能支持float和double型参考代码:#include<stdio.h>#include<math.h>int main(){    int a,b;    int……

c语言不用数组,小白做法

摘要:解题思路:注意事项:参考代码:   #include<stdio.h>int main(){int a,b,i,z,t=0,c=0;for(i=1;i<8;i++){scanf("%d%d",&a,&……