sdut-1158 C语言实验——两个数最大

点击打开链接
Time Limit: 1000MS Memory Limit: 65536KB

Problem Description

求两个整数中的最大值。

Input

两个数。
#include <iostream>
using namespace std;
int main()
{
	int a,b;
	cin>>a>>b;
	if(a>=b)
		cout<<"max="<<a<<endl;
		else
		cout<<"max="<<b<<endl;
		return 0;
}

/***************************************************
User name: YT1658506207邵雪源
Result: Accepted
Take time: 0ms
Take Memory: 204KB
Submit time: 2017-07-26 15:04:46
****************************************************/

Output

输出最大的值,格式为: max=最大值。

Example Input

1 2

Example Output

max=2

原文地址:https://www.cnblogs.com/sxy201658506207/p/7586299.html