제출 #980503

#제출 시각아이디문제언어결과실행 시간메모리
980503vjudge1육각형 영역 (APIO21_hexagon)C++17
컴파일 에러
0 ms0 KiB
#include "hexagon.h"
#include<bits/stdc++.h>
#define sz size()
#define ll long long
using namespace std;
const ll M = 1e9 + 7;
int draw_territory(int N, int A, int B, vector<int> D, vector<int> L)
{
    if(L[0] != L[1] || L[0] != d[2])
        while(true);
    ll ans = ((ll)L[0] + 1ll) * ((ll)L[0] + 2ll) / 2ll * (ll)A % M;
    return int(ans);
}


//void solve()
//{
//}
//
//signed main()
//{
//    ios_base::sync_with_stdio(0);
//    cin.tie(0), cout.tie(0);
////    solve();
//}

컴파일 시 표준 에러 (stderr) 메시지

hexagon.cpp: In function 'int draw_territory(int, int, int, std::vector<int>, std::vector<int>)':
hexagon.cpp:9:32: error: 'd' was not declared in this scope
    9 |     if(L[0] != L[1] || L[0] != d[2])
      |                                ^