记录详情

Compile Error

foo.cc:2:7: error: expected nested-name-specifier before 'namaspace'
    2 | using namaspace std;
      |       ^~~~~~~~~
foo.cc: In function 'void dfs(int)':
foo.cc:10:25: error: invalid conversion from 'const char*' to 'char' [-fpermissive]
   10 |                 g[0][0]="X";
      |                         ^~~
      |                         |
      |                         const char*
foo.cc:16:28: error: scalar object 'sy' requires one element in initializer
   16 |         int sx[]={0,1,2,2},sy={2,1,0,2};
      |                            ^~
foo.cc: In function 'int main()':
foo.cc:27:15: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
   27 |         while(cin>>n)
      |               ^~~
      |               std::cin
In file included from foo.cc:1:
/nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0/include/c++/11.3.0/iostream:60:18: note: 'std::cin' declared here
   60 |   extern istream cin;           /// Linked to standard input
      |                  ^~~
foo.cc:38:41: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   38 |                                         cout<<"X"<<" ";
      |                                         ^~~~
      |                                         std::cout
In file included from foo.cc:1:
/nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0/include/c++/11.3.0/iostream:61:18: note: 'std::cout' declared here
   61 |   extern ostream cout;          /// Linked to standard output
      |                  ^~~~
foo.cc:39:38: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   39 |                                 else cout<<" "<<endl;
      |                                      ^~~~
      |                                      std::cout
In file included from foo.cc:1:
/nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0/include/c++/11.3.0/iostream:61:18: note: 'std::cout' declared here
   61 |   extern ostream cout;          /// Linked to standard output
      |                  ^~~~
foo.cc:39:49: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   39 |                                 else cout<<" "<<endl;
      |                                                 ^~~~
      |                                                 std::endl
In file included from /nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0/include/c++/11.3.0/iostream:39,
                 from foo.cc:1:
/nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0/include/c++/11.3.0/ostream:684:5: note: 'std::endl' declared here
  684 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
foo.cc:41:25: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   41 |                         cout<<endl;
      |                         ^~~~
      |                         std::cout
In file included from foo.cc:1:
/nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0/include/c++/11.3.0/iostream:61:18: note: 'std::cout' declared here
   61 |   extern ostream cout;          /// Linked to standard output
      |                  ^~~~
foo.cc:41:31: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   41 |                         cout<<endl;
      |                               ^~~~
      |                               std::endl
In file included from /nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0/include/c++/11.3.0/iostream:39,
                 from foo.cc:1:
/nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0/include/c++/11.3.0/ostream:684:5: note: 'std::endl' declared here
  684 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
自测
题目
P1453 3-16 分形
语言
C++
递交时间
2023-07-06 23:51:45
评测时间
2023-07-06 23:51:45
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes