两个整数,输出绝对值较大者

#include<iostream.h>
void main()
{
	int a,b;
	cout<<"请输入两个整数"<<endl;
	cin>>a>>b;
	cout<<"a="<<a<<"b="<<b<<endl;//	if(fabs(a)>fabs(b))
		cout<<"a,b中绝对值较大的为:"<<a<<endl;
		else
		cout<<"a,b中绝对值较大的为:"<<b<<endl;
}

原文地址:https://www.cnblogs.com/zztong/p/6695348.html