C语言训练-求1+2!+3!+...+N!的和 摘要:解题思路:先写出每一个数的阶乘的循环体;在加上一个求和即可;(新手小白)注意事项:必须用longlong参考代码:#include <stdio.h>long long fact(int n) { i…… 题解列表 2024年05月20日 0 点赞 0 评论 417 浏览 评分:9.9
蓝桥杯2022年第十三届省赛真题-纸张尺寸 摘要:解题思路:将十张纸的长宽用数组来存参考代码: #include <iostream>using namespace std;int main(int argc, char *argv[]){ int …… 题解列表 2024年05月21日 0 点赞 0 评论 707 浏览 评分:9.9
最长公共子序列 摘要:解题思路:从繁至简注意事项:c参考代码:#include <stdio.h>#include <string.h>int max(int a, int b) { if (a >= b) retu…… 题解列表 2024年05月22日 0 点赞 4 评论 538 浏览 评分:9.9
万变不离其宗 摘要:解题思路:注意事项:参考代码:#include <stdio.h> #define N 10010 int f[N], w[N], v[N]; int main() { i…… 题解列表 2024年05月22日 2 点赞 1 评论 479 浏览 评分:9.9
万变不离其宗 叫我老翟 摘要:解题思路:注意事项:参考代码:#include <stdio.h> #include <stdlib.h> typedef struct node { int start, end,…… 题解列表 2024年05月22日 0 点赞 0 评论 738 浏览 评分:9.9
二级C语言——平均值计算 摘要:解题思路:先在循环中把十个数输入并加起来,之后在另一个循环中挨个跟平均数比较,用k统计大于平均数的数;注意事项:需要使用float参考代码:#include <stdio.h>int main(){ …… 题解列表 2024年05月22日 4 点赞 0 评论 979 浏览 评分:9.9
利润计算(c语言) 摘要:解题思路:将利润除以100000,所得数使用switch函数进行选择。注意事项:参考代码:#include int main(){ int i,t; scanf("%d",&i); int…… 题解列表 2024年05月22日 0 点赞 0 评论 311 浏览 评分:9.9
贪心+二分+逆序获取最小字典序输出 摘要:解题思路:首先得知道什么是最长递增子序列LIS,自行百度,一般有两种做法,一种是一维线性dp复杂度为n^2,另一种是贪心+二分,符合本题的要求。1、很明显游客名单这是一个严格递增子序列,那就按规则建立…… 题解列表 2024年05月22日 0 点赞 0 评论 440 浏览 评分:9.9
1951:求平方和 摘要:参考代码:#include<stdio.h>#include<math.h>int main(){int a=3;int b=4; scanf("%d%d",&a,&b); printf(…… 题解列表 2024年05月23日 0 点赞 0 评论 640 浏览 评分:9.9
1075: 台球碰撞 摘要:解题思路:注意事项:参考代码:#include<iostream> #include<cmath> using namespace std; double l,w,x,y,r,a,v,s; i…… 题解列表 2024年05月24日 1 点赞 0 评论 363 浏览 评分:9.9