Submission #1362606

#TimeUsernameProblemLanguageResultExecution timeMemory
1362606opeleklanosMagic Show (APIO24_show)C++20
Compilation error
0 ms0 KiB
#include <iostream>
#include <vector>
using namespace std;

#include "Alice.h"

#define ll long long;

vector<pair<int, int>> Alice(){
    ll x = setN(5000);
    vector<pair<int, int>> ans;
    for(ll i = 1; i<=5000; i++){
        if(i!=x) ans.push_back({x, i});
    }
    return ans;
}
#include <iostream>
#include <vector>
using namespace std;

#include "Bob.h"

#define ll long long

long long Bob(vector<pair<int, int>> edges){
    ll a = edges[0].first;
    ll b = edges[0].second;
    ll c = edges[1].first;
    ll d = edges[1].second;
    if(a == c) return a;
    if(b == c) return b;
    if(a == d) return a;
    if(b == d) return b;
}

Compilation message (stderr)

# 1번째 컴파일 단계

Alice.cpp: In function 'std::vector<std::pair<int, int> > Alice()':
Alice.cpp:7:17: error: declaration does not declare anything [-fpermissive]
    7 | #define ll long long;
      |                 ^~~~
Alice.cpp:10:5: note: in expansion of macro 'll'
   10 |     ll x = setN(5000);
      |     ^~
Alice.cpp:10:8: error: 'x' was not declared in this scope
   10 |     ll x = setN(5000);
      |        ^
Alice.cpp:7:17: error: declaration does not declare anything [-fpermissive]
    7 | #define ll long long;
      |                 ^~~~
Alice.cpp:12:9: note: in expansion of macro 'll'
   12 |     for(ll i = 1; i<=5000; i++){
      |         ^~
Alice.cpp:12:12: error: 'i' was not declared in this scope
   12 |     for(ll i = 1; i<=5000; i++){
      |            ^
Alice.cpp:12:26: error: expected ')' before ';' token
   12 |     for(ll i = 1; i<=5000; i++){
      |        ~                 ^
      |                          )
Alice.cpp:12:28: error: 'i' was not declared in this scope
   12 |     for(ll i = 1; i<=5000; i++){
      |                            ^