Submission #710370

#TimeUsernameProblemLanguageResultExecution timeMemory
710370lamDuathlon (APIO18_duathlon)C++14
Compilation error
0 ms0 KiB
) for (int j=1; j<=n; j++) for (int z=1; z<=n; z++) if (i!=j&&j!=z&&i!=z) { // if (res[i][j][z]) cout<<i<<' '<<j<<' '<<z<<" !! "<<endl; ans += res[i][j][z]; } cout<<ans<<'\n'; }

Compilation message (stderr)

count_triplets.cpp:1:1: error: expected unqualified-id before ')' token
    1 | )
      | ^
count_triplets.cpp:2:23: error: 'j' does not name a type
    2 |         for (int j=1; j<=n; j++)
      |                       ^
count_triplets.cpp:2:29: error: 'j' does not name a type
    2 |         for (int j=1; j<=n; j++)
      |                             ^
count_triplets.cpp:3:27: error: 'z' does not name a type
    3 |             for (int z=1; z<=n; z++)
      |                           ^
count_triplets.cpp:3:33: error: 'z' does not name a type
    3 |             for (int z=1; z<=n; z++)
      |                                 ^
count_triplets.cpp:9:5: error: 'cout' does not name a type
    9 |     cout<<ans<<'\n';
      |     ^~~~
count_triplets.cpp:10:1: error: expected declaration before '}' token
   10 | }
      | ^