编写题解 2794: 求平均年龄 摘要:解题思路:注意事项:参考代码:#include <stdio.h>int main() { int n; scanf("%d", &n); int a[n]; for (int…… 题解列表 2023年04月25日 0 点赞 0 评论 340 浏览 评分:0.0
[STL训练]寻梦(c语言gets过不了) 摘要:```c #include #include int main() { int n; scanf("%d", &n); getchar(); while (n--) {…… 题解列表 2023年04月25日 0 点赞 1 评论 393 浏览 评分:9.9
[STL训练]壮志难酬(c语言) 摘要:```c int main() { int t; scanf("%d", &t); while (t--) { char str[20] = { 0 }; int n;…… 题解列表 2023年04月25日 0 点赞 0 评论 379 浏览 评分:9.9
动态规划:类似最长递增子序列 摘要:# 动态规划 ## 解题思路 思考:如果求出了所有以每个数字结尾的且和为偶数的数量,则最终的答案是什么? $$ res = 1 + \sum_{1}^n 以nums[i]结尾且和为偶数…… 题解列表 2023年04月25日 0 点赞 1 评论 1004 浏览 评分:9.7
C语言训练-通俗易懂代码---亲密数 摘要:解题思路:第一步:把这3000个数的因子全部统计下来 第二步:利用循环在循环中寻找符合条件的数注意事项:参考代码:#include<stdio.h>int kiss_num(…… 题解列表 2023年04月25日 0 点赞 1 评论 611 浏览 评分:9.9
有点浪费时间,不过稳定通过 摘要:参考代码:def fun(n): min_num=int(n[-1]) n=list(n) del n[-1] new_n='' for i in n: …… 题解列表 2023年04月25日 0 点赞 0 评论 356 浏览 评分:9.9
编写题解 3010: 奇偶数之和 摘要:解题思路:注意事项:参考代码: #include<stdio.h>int main(){ int n; int sum=0,a=0; if(scanf("%d",&n)==EOF){…… 题解列表 2023年04月25日 0 点赞 0 评论 301 浏览 评分:0.0
2760: 整型与布尔型的转换 摘要:解题思路:强制转换就行了注意事项:bool类型在c语言里面没有,要用到头文件#include<stdbool.h>,不过强制转换可以不需要。参考代码:#include<stdio.h>#include…… 题解列表 2023年04月25日 0 点赞 0 评论 559 浏览 评分:0.0
原题链接:整型数据类型存储空间大小 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int a; short b; cout<<sizeof(…… 题解列表 2023年04月25日 0 点赞 0 评论 668 浏览 评分:9.9
2761: Hello, World!的大小 摘要:解题思路:复制"Hello, World!",直接用sizeof()输出。注意事项:直接复制"Hello, World!"的话不要复制双引号,题目的双引号是中文的,无法通过编译。参考代码:#inclu…… 题解列表 2023年04月25日 0 点赞 0 评论 872 浏览 评分:9.9