题解列表
题解 2771:大象喝水(C代码)
摘要:解题思路: 20*1000/v(v为小圆桶体积),只要实现向正无穷取整就行。两种思路:1、通过ceil函数;2、通过(int)取整。注意事项: ceil函数返回的double型;而(int)是向零取整……
1196: 去掉空格(7行)
摘要:解题思路:注意事项:c++多一行,就没用了参考代码:#include <stdio.h>
int main(){
char ch;
while((ch = getchar()) ……
1042: [编程入门]电报加密
摘要:解题思路:注意事项:参考代码:#include <iostream>
#include <string>
using namespace std;
int main()
{
st……
1130: C语言训练-数字母
摘要:解题思路:注意事项:参考代码:#include <iostream>
#include <string>
using namespace std;
int main()
{
st……
1032: [编程入门]自定义函数之字符串连接
摘要:解题思路:注意事项:参考代码:#include <iostream>
#include <string>
using namespace std;
int main()
{
stri……
1031: [编程入门]自定义函数之字符串反转
摘要:解题思路:c++ 有现成的函数注意事项:参考代码:#include <iostream>
#include <string>
#include <algorithm>
using namespa……
1012: [编程入门]字符串分类统计
摘要:解题思路:注意事项:有个一样的题,要用函数参考代码:#include <iostream>
#include <string>
using namespace std;
int main()……
1029: [编程入门]自定义函数处理素数
摘要:解题思路:注意事项:参考代码:#include <iostream>
using namespace std;
int isprime(int a)
{
if (a <= 1) r……
1028: [编程入门]自定义函数求一元二次方程
摘要:解题思路:注意事项:保留三位小数参考代码:#include <iostream>
#include <cmath>
#include <iomanip>
using namespace std;……