有点小乱,仅供参考 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int jue(int a){ if(a<0) return -(a); else return a;}void main(){ int…… 题解列表 2024年03月11日 0 点赞 0 评论 569 浏览 评分:0.0
Jayden-[解释通俗易懂,一看就会! ] 链表合并(功能模块化) 摘要:解题思路: 自定义函数实现功能模块化: 1、创捷链表createList 2、创建节点creatNode 3、插入节点insertNodeByHead(…… 题解列表 2024年03月11日 0 点赞 0 评论 603 浏览 评分:9.9
用%0.2f规定输出格式 摘要:解题思路:注意事项:参考代码:#include<stdio.h>void main(){ int x; double y; scanf("%d",&x); if(x<1)y=x; else if(x>…… 题解列表 2024年03月11日 0 点赞 0 评论 587 浏览 评分:0.0
1023 选择排序 解题思路:注意事项:参考代码:/*思路:首先定义一个整形变量min,用来存储数组中最小数值的下标默认数组第一位元素为min下标使用for循环和if判断更小的元素,找到则把该元素的下标赋予min(而不是在这里就互换两个元素的位置,不然这和冒泡有什么区别呢)直到找到最小的元素下标, 题解列表 2024年03月11日 0 点赞 0 评论 525 浏览 评分:9.9
筛选n以内的完数 c语言 摘要:解题思路:用两个for循环来做,第一个for循环用来从一到n,第二个for循环用来判断是不是素数如果取余为零则说明是因子注意事项:参考代码:#include <stdio.h>int main(){ …… 题解列表 2024年03月11日 0 点赞 0 评论 593 浏览 评分:9.9
用for放高度 摘要:解题思路:注意事项:参考代码:#include<stdio.h>void main(){ int i=0; int apple=0; int hig[10]; int sh; for(;i<10;i+…… 题解列表 2024年03月11日 0 点赞 0 评论 440 浏览 评分:6.0
使用c语言类和对象-函数重载练习-比较大小 摘要:解题思路:注意事项:参考代码:#include#include#includevoid compareInt(int a, int b) { int max = a > b ? a : b; …… 题解列表 2024年03月11日 0 点赞 0 评论 955 浏览 评分:9.9
分解质因数 摘要:解题思路:注意事项:可以不考虑是否是素数,直接对其分解不推荐gotoloop,我只是当时就只想到了gotoloop参考代码:#include<stdio.h>int main(){ long a,b…… 题解列表 2024年03月11日 0 点赞 0 评论 752 浏览 评分:0.0
C语言--等差数列 摘要:解题思路:注意事项:参考代码:#include <stdio.h>int main(){ int n,i,a1,an,sum,d,j; scanf("%d",&n); for(i=0;i<n;i++…… 题解列表 2024年03月10日 0 点赞 0 评论 696 浏览 评分:2.0
c语言 冒泡排序解决 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int n,m; scanf("%d%d",&n,&m); int a=0; …… 题解列表 2024年03月10日 0 点赞 0 评论 540 浏览 评分:9.9