Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
111059 常钰杰 比较三个数大小II C++ Accepted 1 MS 272 KB 469 2025-02-25 21:41:00

Tests(1/1):


Code:

#include<iostream> using namespace std; int main() { int a,b,c; cin>>a>>b>>c; if(a>b&&a>c) { if(b>c) { cout<<c<<" "<<b<<" "<<a; } else { cout<<b<<" "<<c<<" "<<a; } } else if(b>a&&b>c) { if(a>c) { cout<<c<<" "<<a<<" "<<b; } else { cout<<a<<" "<<c<<" "<<b; } } else if(c>b&&c>a) { if(a>b) { cout<<b<<" "<<a<<" "<<c; } else { cout<<a<<" "<<b<<" "<<c; } } return 0; }