QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#100307#4889. 愚蠢的在线法官goodmanCompile Error//C++608b2023-04-25 15:38:362023-04-25 15:38:39

Details

answer.code:15:5: error: expected initializer before ‘cin’
   15 |     cin>>n>>m;
      |     ^~~
answer.code:16:5: error: expected unqualified-id before ‘for’
   16 |     for(i=1;i<=n;i++)scanf("%lld",&val[i]);
      |     ^~~
answer.code:16:13: error: ‘i’ does not name a type
   16 |     for(i=1;i<=n;i++)scanf("%lld",&val[i]);
      |             ^
answer.code:16:18: error: ‘i’ does not name a type
   16 |     for(i=1;i<=n;i++)scanf("%lld",&val[i]);
      |                  ^
answer.code:17:5: error: expected unqualified-id before ‘for’
   17 |     for(i=1;i<=m;i++)scanf("%d",&a[i]);
      |     ^~~
answer.code:17:13: error: ‘i’ does not name a type
   17 |     for(i=1;i<=m;i++)scanf("%d",&a[i]);
      |             ^
answer.code:17:18: error: ‘i’ does not name a type
   17 |     for(i=1;i<=m;i++)scanf("%d",&a[i]);
      |                  ^
answer.code:18:5: error: expected unqualified-id before ‘for’
   18 |     for(i=1;i<n;i++){
      |     ^~~
answer.code:18:13: error: ‘i’ does not name a type
   18 |     for(i=1;i<n;i++){
      |             ^
answer.code:18:17: error: ‘i’ does not name a type
   18 |     for(i=1;i<n;i++){
      |                 ^
answer.code:24:8: error: expected constructor, destructor, or type conversion before ‘(’ token
   24 |     dfs(1,0);
      |        ^
answer.code:25:5: error: ‘cout’ does not name a type
   25 |     cout<<ans<<endl;
      |     ^~~~
answer.code:26:1: error: expected declaration before ‘}’ token
   26 | }
      | ^