C语言程序设计教程(第三版)课后习题1.6 (C语言代码) 摘要:解题思路:通过使用三目运算符来解题注意事项:参考代码:#include<stdio.h>int main(){ int a,b,c,max; scanf("%d %d %d",&a,&b,…… 题解列表 2018年05月16日 0 点赞 0 评论 586 浏览 评分:0.0
半数集问题 (C++代码) 摘要:解题思路:注意事项:参考代码:#include<iostream> #include<cstring> using namespace std; int a[1005]; int f(int …… 题解列表 2018年05月16日 0 点赞 0 评论 1410 浏览 评分:9.9
新手发表课后习题8.2 (C语言代码) 摘要:解题思路:调用 math.h 函数库 使用求根公式注意事项:算delta时注意运算优先级、输出x1,x2时保留小数参考代码:#include<stdio.h>#include<math.h>void …… 题解列表 2018年05月16日 1 点赞 0 评论 1309 浏览 评分:0.0
小O的溢出 (C语言代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int book[1000]={0},max=0,h;void dfs(int a[],int n,int t){ int i; …… 题解列表 2018年05月16日 2 点赞 0 评论 1073 浏览 评分:0.0
十->二进制转换 (C++代码) 摘要:解题思路:注意事项:参考代码:#include<iostream> using namespace std; int a[20]={0}; int main() { int n; wh…… 题解列表 2018年05月16日 0 点赞 0 评论 1159 浏览 评分:0.0
蓝桥杯算法提高VIP-促销购物 (C语言代码)--------------C语言——菜鸟级 摘要:解题思路: 动态规划 完全背包 变形 注意事项:参考代码:#include<stdio.h> #include<string.h> long int bj(long int a,long in…… 题解列表 2018年05月16日 5 点赞 0 评论 2024 浏览 评分:9.9
【数组的距离】 (C语言代码)------------------C语言——菜鸟级 摘要:解题思路:将先第一数组储存起来 输入第二数组时 每输入一位输入 去与第一数组元素遍历找到 当前最优数组距离(优化:因为数组元素为单调递增所以距离的结果也为单调 如果当前处理与第一数组的元素大于前面处理…… 题解列表 2018年05月16日 5 点赞 0 评论 1551 浏览 评分:0.0
【偶数求和】 (C语言代码)-----------------C语言——菜鸟级 摘要:解题思路:因为是等差数列 所以 根据 sum= (a0+an)*n/2; an=a0+(n-1)*d ave=sum/n=(2*a0+…… 题解列表 2018年05月16日 4 点赞 0 评论 996 浏览 评分:0.0
【亲和数】 (C语言代码)------------C语言——菜鸟级 摘要:解题思路:题简单就不说 看代码 注意事项:参考代码:#include<stdio.h> int qhs(long int a,long int b) { long int i,t,sum=0;…… 题解列表 2018年05月16日 2 点赞 0 评论 1069 浏览 评分:0.0
【排队买票】 (C语言描述 6ms 过 简单易懂)-----------------C语言——菜鸟级 摘要:解题思路: 比较简单 先不管 排不排序 先把 满足条件的 情况通过递归得到数目 再针对 1 元的小朋友 和 2 元的小朋友 分别 进行内部全排 (即求 n! 和 k!) 比如样例 4 2 2 …… 题解列表 2018年05月16日 24 点赞 0 评论 2052 浏览 评分:9.3