threenum.cpp

来自「c语言程序设计,ppt格式」· C++ 代码 · 共 28 行

CPP
28
字号
#include <iostream.h>
main()
{
int x,y,z;
int temp=-1;
cout<<"Please input three number"<<endl;
cin>>x>>y>>z;
if (x<y)
  {
	temp=x;
	x=y;
	y=temp;
  }
if(x<z)
  {
	temp=z;
	z=x;
	x=temp;
  }
if (y<z)
  {
	temp=y;
	y=z;
	z=temp;
  }
cout<<x<<y<<z;
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?