从大到小排列三个数字

int main(){    int a = 0;    int b = 0;    int c = 0;    scanf("%d%d%d", &a, &b, &c);//此处输入时数字之间要加空格    if (a<b)    {        int tmp = a;        a = b;        b = tmp;    }    if (a<c)    {        int tmp = a;        a = c;        c = tmp;    }    if (b<c)    {        int tmp = b;        b = c;        c = tmp;    }    printf("%d %d %d\n", a, b, c);    return 0;} //从大到小排列三个数字
©著作权归作者所有:来自51CTO博客作者大圣?的原创作品,如需转载,请注明出处,否则将追究法律责任

更多相关文章

  1. 我的第24个代码
  2. 2020年,企业数字化转型的思考总结
  3. 我的第21个代码
  4. 我的第13个代码
  5. 我的第十个代码
  6. 2021-02-17:规定1和A对应、2和B对应、3和C对应...26和Z对应,那么一
  7. 我的第九个代码
  8. 我的第八个代码
  9. 我的第六个代码

随机推荐

  1. android:layout_gravity与android:gravit
  2. Android初级之路-Android发展史
  3. Android GWES之Android窗口管理
  4. android系统硬件抽象层(HAL)原理及实现之原
  5. Android环境变量配置
  6. Android响应按钮的程序结构
  7. android textview
  8. Android RelativeLayout 属性
  9. android线性布局控件之间的距离设置
  10. 高级Android工程师进阶系列文章汇总