题解 | #简单运算#
简单运算
https://www.nowcoder.com/practice/23c9b22d40fa4d7698a1306fb0c9f975
#include <iostream> using namespace std; int main() { int x,y; cin>>x>>y; if(x<y){ swap(x,y); } cout<<x+y<<" "<<x-y<<" "<<x*y<<" "<<x/y<<" "<<x%y; return 0; }
简单运算
https://www.nowcoder.com/practice/23c9b22d40fa4d7698a1306fb0c9f975
#include <iostream> using namespace std; int main() { int x,y; cin>>x>>y; if(x<y){ swap(x,y); } cout<<x+y<<" "<<x-y<<" "<<x*y<<" "<<x/y<<" "<<x%y; return 0; }
相关推荐