题解列表
利用getline()和istringstream()解决字符串读入空格问题
摘要: #include
#include //STL中的set
#include
using namespace std;
int main()
……
编写题解 1152: C语言训练-计算:t=1-1/(2*2)-1/(3*3)-...-1/(m*m)
摘要:解题思路:注意事项:参考代码:#include<iostream>#include <iomanip>#include<math.h>using namespace std;int main(){ ……
编写题解 1151: C语言训练-计算一个整数N的阶乘
摘要:解题思路:注意事项:参考代码:#include<iostream>#include <iomanip>using namespace std;int main(){ int n; int ……
编写题解 1150: C语言训练-计算t=1+1/2+1/3+...+1/n
摘要:解题思路:注意事项:参考代码:#include
#include
using namespace std;
int main()
{
int n;
double sum =……
编写题解 1149: C语言训练-计算1~N之间所有奇数之和
摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int n; int sum =0; cin>>n;……
陶陶摘苹果之遍历数组
摘要:解题思路: 用最大高度加上30cm之后 遍历数组中的十个数字 能满足就计数加一 注意事项:参考代码:#include<bits/stdc++.h>using namespace std……
编写题解 1585: 蓝桥杯算法训练VIP-链表数据求和操作 C++
摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;struct Node { int data; //实部 int data1; ……
1098: 陶陶摘苹果题解
摘要:解题思路:这题很简单,我们需要一个数组a[10]来统计每个苹果距离地面的高度,然后判断陶陶把手伸直的时候能够达到的最大高度加上板凳的高度30是否大于每个苹果距离地面的高度,如果大于,计数器就自加,输出……