良心出品,放心食用 摘要:解题思路:这段代码定义了一个数组 A ,并通过循环计算出 N 在一定范围内(小于 55)时对应的某种数量值 A[N - 1] ,然后根据输入的 N 值输出相应的结果。在代码中,首先初始…… 题解列表 2024年11月21日 1 点赞 0 评论 502 浏览 评分:10.0
感觉你们应该可以看懂,有两种药方 摘要:解题思路:注意事项:参考代码://方法一:#include <stdio.h>#include<string.h> void q(char x[100],int y[4]){ int len=0; …… 题解列表 2024年11月22日 0 点赞 0 评论 941 浏览 评分:10.0
题解 2913: 整数去重 菜鸟解法 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int i,j,n; scanf("%d",&n); int a[n]; for(i=0…… 题解列表 2024年11月22日 2 点赞 0 评论 728 浏览 评分:10.0
定义一个长度为10的数组存放尾数0到9的最大长度来解决问题 解题思路:由于每个数只要头和尾,而其中尾只能是0到9,即使当尾为0时不能继续接,也要用10个参数来储存尾巴为0到9的最大长度即可。p[10]的1到9对应当前尾巴为1到9的长度最长的值,所以每拿到一个新的数,只要检测这个数接上去是否可以使某一个数组最大值增加。 题解列表 2024年11月22日 8 点赞 0 评论 1319 浏览 评分:10.0
3 5 7整除(c语言) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a; scanf("%d", &a); if((a%3==0) && (a%5==0) && (a%7=…… 题解列表 2024年11月22日 1 点赞 0 评论 731 浏览 评分:10.0
2002题解方法 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ char a[100]; int i,t=0; gets(a); for(i=0;a[i]!='\0&#…… 题解列表 2024年11月22日 0 点赞 0 评论 527 浏览 评分:10.0
Hanoi双塔问题——递归+高精度运算 解题思路:单塔:2n-1双塔:2*(2n-1)高精度乘低精度高精度的减法删除多余的前导零注意事项:参考代码: 题解列表 2024年11月23日 1 点赞 0 评论 759 浏览 评分:10.0
核电站问题(C语言) 摘要:解题思路:定义了一个名为 fun 的函数来计算一个与给定整数 n 相关的数值,并在 main 函数中通过输入 n 来调用 fun 函数并输出结果在 fun 函数中,对于 n …… 题解列表 2024年11月23日 0 点赞 0 评论 520 浏览 评分:10.0
自定义函数求一元二次方程 摘要:#include<bits/stdc++.h> using namespace std; int main() { double a,b,c,x1,x2;cin>>a>>b>>c; …… 题解列表 2024年11月23日 2 点赞 0 评论 1587 浏览 评分:10.0
1017: [编程入门]完数的判断 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int main(){ int i, j, n, sum; cin >>…… 题解列表 2024年11月23日 0 点赞 0 评论 631 浏览 评分:10.0