Compile Error

foo.cc: In function 'int main()':
foo.cc:6:16: error: expected ';' before 'cin'
    6 |  int n,i,j,t;33
      |                ^
      |                ;
    7 |  cin>>n;
      |  ~~~            
foo.cc:6:14: warning: statement has no effect [-Wunused-value]
    6 |  int n,i,j,t;33
      |              ^~
foo.cc:9:3: error: 'cin' was not declared in this scope
    9 |   cin>>a[i];
      |   ^~~
foo.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
    1 | #include <cstdio>
  +++ |+#include <iostream>
    2 | using namespace std;
foo.cc:22:3: error: 'cout' was not declared in this scope
   22 |   cout<<a[0]<<" ";
      |   ^~~~
foo.cc:22:3: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
P1060 数组元素最大值
语言
C++
递交时间
2022-01-12 08:11:19
评测时间
2022-01-12 08:11:19
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes