1635: 蓝桥杯算法训练VIP-整数平均值(简单解法) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int add(int n) //定义函数add{ int *p,a[100]={0},i,sum=0; //定义指针…… 题解列表 2024年10月31日 2 点赞 0 评论 440 浏览 评分:9.9
蓝桥杯算法训练VIP-整数平均值 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int n; scanf("%d",&n); int i,sum=0,p=0; for(…… 题解列表 2024年10月27日 0 点赞 0 评论 240 浏览 评分:9.9
1635: 蓝桥杯算法训练VIP-整数平均值 摘要:**题目描述:**编写函数,求包含n个元素的整数数组中元素的平均值。要求在函数内部使用指针操纵数组元素,其中n个整数从键盘输入,输出为其平均值。 (样例说明:5为输入数据的个数,3 4 0…… 题解列表 2024年07月14日 2 点赞 0 评论 618 浏览 评分:9.9
蓝桥杯算法训练VIP-整数平均值 摘要:解题思路:1.封装成函数,传入数据量n即可,函数返回平均值,2.函数通过循环获取输入,并累加求和,3.计算平均值,函数结果回传注意事项:此题要求得到平均值,但结果是一个整数,如例子给出的 3 4 0 …… 题解列表 2024年06月01日 0 点赞 0 评论 104 浏览 评分:0.0
C语言 1635 整数平均值 不用指针数组 摘要:参考代码:#include <stdio.h> #include <string.h> #include <math.h> #include <stdlib.h> #include <ctyp…… 题解列表 2024年04月15日 0 点赞 0 评论 97 浏览 评分:0.0
蓝桥杯算法训练VIP-整数平均值 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a[100]; int i; int b; int c=0; scanf("%…… 题解列表 2024年04月12日 0 点赞 0 评论 131 浏览 评分:0.0
1635(c语言解法) 摘要:解题思路: 1.创建数组 2.指针指向数组3.每拿到一个数据指针就往后移注意事项:参考代码:#include<stdio.h>#define maxsize 10int main(){ i…… 题解列表 2024年03月24日 0 点赞 0 评论 148 浏览 评分:0.0
蓝桥杯算法训练VIP-整数平均值 摘要:解题思路:注意事项:参考代码:#include<stdio.h> int main() { int i,n; int sum=0,ave; scanf("%d",&n); int …… 题解列表 2023年12月11日 0 点赞 0 评论 210 浏览 评分:6.0
整数平均值(报错) 摘要:解题思路:注意事项在这个代码运行时,报错error ld returned 1 exit status这个问题其实我代码本身没有问题,是因为我上一个代码运行结果未关闭造成的报错。error ld re…… 题解列表 2023年12月06日 0 点赞 0 评论 68 浏览 评分:0.0