1038: [编程入门]宏定义练习之三角形面积 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;int main(){ double a,b,c; cin >> a>…… 题解列表 2023年12月16日 0 点赞 0 评论 62 浏览 评分:0.0
[编程入门]宏定义练习之三角形面积-题解(C语言代码) 摘要:解题思路: C语言中的宏允许带有参数,包含形参和实参,在宏定义中的参数称为形式参数,在宏调用中的参数称为实际参数,无参宏的宏名后不带参数,其定义的一般形式为: #define 标识符 字符串…… 题解列表 2019年06月07日 0 点赞 0 评论 780 浏览 评分:0.0
[编程入门]宏定义练习之三角形面积-题解(C语言代码) 摘要:解题思路:注意事项:它不是说要一个带参数的宏吗?它来了,它来喽。没什么特别要注意的,注意头文件打上就行参考代码:#include <stdio.h>#include <math.h>#define S…… 题解列表 2020年08月20日 0 点赞 0 评论 323 浏览 评分:0.0
1038: [编程入门]宏定义练习之三角形面积 摘要:解题思路:注意事项:参考代码:#include<stdio.h> #define swap(a,b,c) s=(a+b+c)/2; #define get(a,b,c,s) area=pow((s…… 题解列表 2022年06月13日 0 点赞 0 评论 90 浏览 评分:0.0
C语言程序设计教程(第三版)课后习题9.3 (C语言代码) 摘要:解题思路:注意事项:参考代码:#include <stdio.h>#include <math.h>#define s(a,b,c,S) S=(a+b+c)/2#define area(a,b,c,S…… 题解列表 2018年12月17日 0 点赞 0 评论 309 浏览 评分:0.0
C语言程序设计教程(第三版)课后习题9.3 (C语言代码) 摘要:#include<stdio.h> #include <math.h> #define S(a,b,c) ((a+b+c)/2) #define area(S,a,b,c) (sqrt(…… 题解列表 2017年10月17日 0 点赞 0 评论 866 浏览 评分:0.0
[编程入门]宏定义练习之三角形面积-题解(C语言代码) 摘要:解题思路:了解宏定义的基本概念,根据题目所给信息进行编程注意事项:切记 :输入的格式为双精度, 题目所给的信息中含有sqrt,因此要使用数学头文件参…… 题解列表 2021年01月25日 0 点赞 0 评论 242 浏览 评分:0.0
滴滴滴 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<math.h>#define S(a,b,c) (1.0*(a+b+c)/2)#define area(s,a,b,c…… 题解列表 2018年03月27日 0 点赞 0 评论 688 浏览 评分:0.0
[编程入门]宏定义练习之三角形面积-题解(C语言代码) 摘要: #include #include #define area(S,a,b,c) area=sqrt(S*(S-a)*(S-b)*(S-c)) #define S(…… 题解列表 2020年03月10日 0 点赞 0 评论 258 浏览 评分:0.0
1038: [编程入门]宏定义练习之三角形面积 摘要:解题思路:注意事项:参考代码:import matha,b,c = map(int,input().split())s = (a+b+c)/2print("{:.3f}".format(math.sq…… 题解列表 2022年04月07日 0 点赞 0 评论 808 浏览 评分:0.0