题目链接:http://codeforces.com/problemset/problem/463/B

求个最大值
AC代码:

#include<cstdio>
#include<climits>
using namespace std;

int main() {
    int n,x;
    int maxn;
    while(scanf("%d",&n) != EOF) {
        maxn = INT_MIN;
        while(n--) {
            scanf("%d",&x);
            if(maxn < x)
                maxn = x;
        }
        printf("%d\n",maxn);
    }
    return 0;
}

相关文章:

  • 2021-09-10
  • 2021-09-24
  • 2021-12-25
  • 2021-10-18
  • 2021-11-03
  • 2021-05-29
  • 2021-09-11
  • 2022-12-23
猜你喜欢
  • 2021-07-02
  • 2021-11-17
  • 2021-08-14
  • 2022-12-23
  • 2021-10-22
  • 2021-07-21
  • 2021-10-07
相关资源
相似解决方案