热门

最新

红包

立Flag

投票

同城

我的

发布
qq_31821809
无问.如风
4 年前
trueqq_31821809

转发

从B站审核变慢现象,聊聊谛听安全内容社区产品的内容风控

CSDN App 扫码分享
分享
1
点赞
打赏
  • 复制链接
  • 举报
下一条:
#include<iostream>//compare the amount of five nums 1.0using namespace std;int main(){ int a,b,c,d,e; cout<<"plesase input 5 num"<<"systerm will tell you which one is the bigest"<<endl; cin>>a>>b>>c>>d>>e;//相当于scanf int arr[5]={a,b,c,d,e}; int temp=arr[0]; int i=1; while (i<20) { i++;//i is used to limit the times of while if(arr[0]>arr[1]){ temp=arr[0]; arr[0]=arr[1]; arr[1]=temp; } if(arr[1]>arr[2]){ temp=arr[1]; arr[1]=arr[2]; arr[2]=temp; } if(arr[2]>arr[3]){ temp=arr[2]; arr[2]=arr[3]; arr[3]=temp; } if(arr[3]>arr[4]){ temp=arr[3]; arr[3]=arr[4]; arr[4]=temp; } } cout<<arr[0]<<"<"<<arr[1]<<"<"<<arr[2]<<"<"<<arr[3]<<"<"<<arr[4]; return 0;}
立即登录