题解列表

筛选

兰顿蚂蚁 (C++代码)

摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int a[100][100]={0};int main(){ int m,n; while(……

求组合数 (C语言代码)

摘要:解题思路:ctrl + Z 再回车 ==  EOF注意事项:参考代码:#include<stdio.h>int main(){    int m,n,i;    while(scanf("%d%d",……

C语言程序设计教程(第三版)课后习题6.11 (C语言代码)

解题思路:这道题的算法是下一个值和上一个值有直接的关联,很明显可以使用递归求解。注意事项:在这里求两个数之间的差值,使用math.h的方法,但是要注意abs和fabs的区别,一个整数使用,一个浮点数使用。参考代码:#include#includedoublecalcu

WU-字符串比较 (C++代码)

摘要: 直接调用c++特性string 流来解决问题参考代码:#include<iostream> #include<cstring> using namespace std; int main()……

【偶数求和】 (C语言代码)

摘要:解题思路:注意事项:解这题是我感觉注意的就是如果n不是m的倍数需要注意,参考代码:#include<stdio.h>int main(void){ int num[100]; int n,m,sum=……

WU-整数平均值 (C++代码)

摘要:解题思路:用指针操作数组元素参考代码:#include<iostream> using namespace std; int a[1000]; void f(int a[],int n) { ……