码迷,mamicode.com
首页 > 其他好文 > 详细

1157. The hardest problem

时间:2016-10-22 14:54:48      阅读:224      评论:0      收藏:0      [点我收藏+]

标签:space   iostream   turn   std   int   bsp   stream   cout   amp   

#include<iostream>
using namespace std;
int main()
{
 int n;
 while(cin>>n&&n!=0&&n<=4){
        int t;
  int max=0;
  for(int i=0;i<n;i++){
   cin>>t;
   if(t>max) max=t;
  }
  cout<<max<<endl;
 }
 return 0;
}

1157. The hardest problem

标签:space   iostream   turn   std   int   bsp   stream   cout   amp   

原文地址:http://www.cnblogs.com/sysu-eeman-yang/p/5987453.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!