当前位置:网站首页>27. 输入3个整数,按从大到小的次序输出。要求用指针方法实现。
27. 输入3个整数,按从大到小的次序输出。要求用指针方法实现。
2022-07-03 16:51:00 【我不是萧海哇~~~~】
int sortnum(int *a,int *b ,int *c)
{
int minnum=min(min(*a,*b),*c);
int maxnum=max(max(*a,*b),*c);
int midnum=*a+*b+*c-minnum-maxnum;
printf("%d %d %d\n",maxnum,midnum,minnum);
}
边栏推荐
- Is it safe to open a stock account by mobile registration? Does it need money to open an account
- On Lagrange interpolation and its application
- How to allow remote connection to MySQL server on Linux system?
- The word backspace key cannot delete the selected text, so you can only press Delete
- Threejs Part 2: vertex concept, geometry structure
- 2022.02.14_ Daily question leetcode five hundred and forty
- How to promote cross department project collaboration | community essay solicitation
- One article takes you to understand machine learning
- [JDBC] API parsing
- What material is 13crmo4-5 equivalent to in China? 13crmo4-5 chemical composition 13crmo4-5 mechanical properties
猜你喜欢
arduino-esp32:LVGL项目(一)整体框架
Arduino esp32: overall framework of lvgl project (I)
What kind of material is 14Cr1MoR? Analysis of chemical composition and mechanical properties of 14Cr1MoR
关于视觉SLAM的最先进技术的调查-A survey of state-of-the-art on visual SLAM
[JDBC] API parsing
What material is sa537cl1? Sa537cl1 corresponds to the national standard material
美团一面:为什么线程崩溃崩溃不会导致 JVM 崩溃
13mnnimo5-4 German standard steel plate 13MnNiMo54 boiler steel 13MnNiMo54 chemical properties
CC2530 common registers for port initialization
【LeetCode】94. Middle order traversal of binary tree
随机推荐
Deep understanding of grouping sets statements in SQL
NSQ source code installation and operation process
关于视觉SLAM的最先进技术的调查-A survey of state-of-the-art on visual SLAM
[combinatorics] non descending path problem (number of non descending paths with constraints)
2022 love analysis · panoramic report of digital manufacturers of state-owned enterprises
How to set up SVN server on this machine
Hong Kong Polytechnic University | data efficient reinforcement learning and adaptive optimal perimeter control of network traffic dynamics
Necessary ability of data analysis
Meituan side: why does thread crash not cause JVM crash
深入理解 SQL 中的 Grouping Sets 语句
"The NTP socket is in use, exiting" appears when ntpdate synchronizes the time
Mysql database DDL and DML
What material is sa537cl2 equivalent to in China? Sa537cl2 corresponding material
ucore概述
(Supplement) double pointer topic
Hands on in-depth learning notes (XIV) 3.7 Simple implementation of softmax regression
MySQL converts comma separated attribute field data from column to row
Aike AI frontier promotion (7.3)
香港理工大学|数据高效的强化学习和网络流量动态的自适应最优周界控制
CC2530 common registers for crystal oscillator settings