主站
DreamJudge
院校信息
专业题库
模拟考试
机试真题
上岸课程
讨论区
兑换中心
登录
注册
上岸
以下题解仅供学习参考使用。
抄袭、复制题解,以达到刷AC率/AC数量或其他目的的行为,在N诺是严格禁止的。
N诺非常重视学术诚信。此类行为将会导致您成为作弊者。具体细则请查看N诺社区规则。
Chen沧月有泪
2025年2月20日 10:13
三个数的最大值 题解:
P1036
回复 0
|
赞 0
|
浏览 61
#include<iostream> int main() { int a = 0, b = 0, c = 0; std::cin >> a >> b >> c; int max = a > b ? (a > c ? a : c) : (b > c ? b : c); std::cout << max; }
2024上岸
2024年2月18日 18:19
三个数的最大值 题解:
P1036
回复 3
|
赞 5
|
浏览 856
#include<iostream> #include<algorithm> using namespace std; int main() { int a,b,c; cin>>a>>b>>c; cout<<max({a,b,c})<<endl; return 0; }
jisuanji111
2025年2月18日 15:38
三个数的最大值 题解:
P1036
回复 0
|
赞 0
|
浏览 69
#include <bits/stdc++.h> using namespace std; int main(){ int a[3]; scanf("%d %d %d", &a[0], &a[1], &a[2]); int a_max = a[0]; for(int i=1; i<3; i++){ ...
活着的传奇
2023年8月25日 09:55
三个数的最大值 题解:
P1036
回复 0
|
赞 0
|
浏览 824
#include<bits/stdc++.h> using namespace std; int main(){ int a,b,c; cin>>a>>b>>c; printf("%d",c>(a>b?a:b)?c:(a>b?a:b)); return 0; }
Hegel
2023年3月20日 19:32
三数最大值(三目运算符的使用)
P1036
回复 0
|
赞 0
|
浏览 3.1k
#include <iostream> using namespace std; int main() { int a,b,c; while (cin >> a>>b>>c) { int temp = a>b?a:b; int res = temp>c?temp:c; cout<<res<<endl; } return 0; }
LianG_nnuo
2022年11月11日 21:49
c 简单排序
P1036
回复 0
|
赞 2
|
浏览 3.7k
#include<stdio.h> #include<stdlib.h> #include<string.h> #include<math.h> #include<time.h> #include<malloc.h> void main(){ int i,a[3],max; for(i=0;i<3;i++) { ...
nooknook
2021年11月28日 19:43
C_冒泡排序法求最大值
P1036
回复 0
|
赞 0
|
浏览 8.0k
#include<stdio.h> #define N 3 int main() { int a[N]; int i, j, t; for (int i = 0; i < N; i++) scanf("%d", &a[i]); for (i = 0; i < N; i++) for (j = 0; j < N-1; j++) if (a[j] > a[j + 1]) { t = a[j]; a[j] = a[j + 1]; a[j + 1] = t; }...
A1120161820
2020年3月25日 10:37
三个数的最大值(c++)
P1036
回复 0
|
赞 0
|
浏览 11.0k
#include<iostream> using namespace std; int main() { int a, b, c, ans; cin >> a >> b >> c; ans = a; if (b > ans) ans = b; if (c > ans) ans = c; cout << ans << endl; return 0; }
hectorwill
2020年3月22日 16:49
最大最小值
P1036
回复 0
|
赞 1
|
浏览 9.5k
#include<bits/stdc++.h> using namespace std; int main(){ int a,b,c; cin>>a>>b>>c; cout<<max({a,b,c}); return 0; }
莫小七
2020年2月21日 15:17
1036三个数最大数
P1036
回复 0
|
赞 0
|
浏览 8.4k
#include<iostream> using namespace std; int main(){ int a,b,c; cin >> a >> b >> c; cout << ((a>b?a:b)>c?(a>b?a:b):c); return 0; } 暴力解决!!!
1
2
题目
三个数的最大值
题解数量
11
发布题解
快速答疑
热门题解
1
三个数的最大值 题解:
2
c 简单排序
3
最大最小值
4
三个数的最大值 <------转换的思想
5
1036三个数最大数
6
三个数的最大值(c++)
7
三个数的最大值 题解:
8
三数最大值(三目运算符的使用)
9
三个数的最大值 题解:
10
三个数的最大值 题解: