题解列表

筛选

二级C语言——平均值计算

摘要:解题思路:先在循环中把十个数输入并加起来,之后在另一个循环中挨个跟平均数比较,用k统计大于平均数的数;注意事项:需要使用float参考代码:#include <stdio.h>int main(){ ……

蓝桥杯2022年第十三届决赛真题-齿轮

摘要:解题思路:通过列出算式 q=a1/a2*a2/a3*a3......an-2/an-1*an-1/an发现可以约掉中间部分只剩下头尾得到q=a1/an阅读题目发现q为整数,那么可得 a1%an=0且a……

万变不离其宗 叫我老翟

摘要:解题思路:注意事项:参考代码:#include <stdio.h>  #include <stdlib.h>    typedef struct node {      int start, end,……

万变不离其宗

摘要:解题思路:注意事项:参考代码:#include <stdio.h>    #define N 10010    int f[N], w[N], v[N];    int main() {      i……

最长公共子序列

摘要:解题思路:从繁至简注意事项:c参考代码:#include <stdio.h>#include <string.h>int max(int a, int b) {    if (a >= b) retu……

1646: 蓝桥杯算法训练VIP-比较字符串

摘要:解题思路:库里有strcmp函数,返回的就是第一个不一样的位置成功返回0注意事项:参考代码:    #include<iostream>    #include<string>    #include……