portal.cpp: In function 'void solve()':
portal.cpp:35:32: error: 'a' was not declared in this scope
35 | cin >> a[i][j];
| ^
portal.cpp:38:25: error: 'd' was not declared in this scope
38 | d[i][j] = inf;
| ^
portal.cpp:38:35: error: 'inf' was not declared in this scope; did you mean 'ynf'?
38 | d[i][j] = inf;
| ^~~
| ynf
portal.cpp:45:29: error: 'a' was not declared in this scope
45 | if (a[i][j] == '#') lst = j;
| ^
portal.cpp:46:25: error: 'go' was not declared in this scope
46 | go[i][j][0] = {i, lst + 1};
| ^~
portal.cpp:51:29: error: 'a' was not declared in this scope
51 | if (a[i][j] == '#') lst = j;
| ^
portal.cpp:52:25: error: 'go' was not declared in this scope
52 | go[i][j][1] = {i, lst - 1};
| ^~
portal.cpp:58:29: error: 'a' was not declared in this scope
58 | if (a[i][j] == '#') lst = i;
| ^
portal.cpp:59:25: error: 'go' was not declared in this scope
59 | go[i][j][2] = {lst + 1, j};
| ^~
portal.cpp:64:29: error: 'a' was not declared in this scope
64 | if (a[i][j] == '#') lst = i;
| ^
portal.cpp:65:25: error: 'go' was not declared in this scope
65 | go[i][j][3] = {lst - 1, j};
| ^~
portal.cpp:70:9: error: 'd' was not declared in this scope
70 | d[s.fr][s.sc] = 0; pq.push({0, s.fr, s.sc});
| ^
portal.cpp:76:22: warning: structured bindings only available with '-std=c++17' or '-std=gnu++17'
76 | auto [dis, x, y] = pq.top(); pq.pop();
| ^
portal.cpp:80:38: error: 'dx' was not declared in this scope; did you mean 'nx'?
80 | int nx = x + dx[i], ny = y + dy[i];
| ^~
| nx
portal.cpp:81:39: error: 'ny' was not declared in this scope; did you mean 'nx'?
81 | if (valid(nx, ny) && a[nx][ny] != '#' && umin(d[nx][ny], d[x][y] + 1)) pq.push({d[nx][ny], nx, ny});
| ^~
| nx
portal.cpp:81:46: error: 'a' was not declared in this scope
81 | if (valid(nx, ny) && a[nx][ny] != '#' && umin(d[nx][ny], d[x][y] + 1)) pq.push({d[nx][ny], nx, ny});
| ^
portal.cpp:81:123: error: no matching function for call to 'std::priority_queue<std::array<int, 3>, std::vector<std::array<int, 3> >, std::greater<std::array<int, 3> > >::push(<brace-enclosed initializer list>)'
81 | if (valid(nx, ny) && a[nx][ny] != '#' && umin(d[nx][ny], d[x][y] + 1)) pq.push({d[nx][ny], nx, ny});
| ^
In file included from /usr/include/c++/10/queue:64,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:86,
from portal.cpp:1:
/usr/include/c++/10/bits/stl_queue.h:640:7: note: candidate: 'void std::priority_queue<_Tp, _Sequence, _Compare>::push(const value_type&) [with _Tp = std::array<int, 3>; _Sequence = std::vector<std::array<int, 3> >; _Compare = std::greater<std::array<int, 3> >; std::priority_queue<_Tp, _Sequence, _Compare>::value_type = std::array<int, 3>]'
640 | push(const value_type& __x)
| ^~~~
/usr/include/c++/10/bits/stl_queue.h:640:30: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'const value_type&' {aka 'const std::array<int, 3>&'}
640 | push(const value_type& __x)
| ~~~~~~~~~~~~~~~~~~^~~
/usr/include/c++/10/bits/stl_queue.h:648:7: note: candidate: 'void std::priority_queue<_Tp, _Sequence, _Compare>::push(std::priority_queue<_Tp, _Sequence, _Compare>::value_type&&) [with _Tp = std::array<int, 3>; _Sequence = std::vector<std::array<int, 3> >; _Compare = std::greater<std::array<int, 3> >; std::priority_queue<_Tp, _Sequence, _Compare>::value_type = std::array<int, 3>]'
648 | push(value_type&& __x)
| ^~~~
/usr/include/c++/10/bits/stl_queue.h:648:25: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::priority_queue<std::array<int, 3>, std::vector<std::array<int, 3> >, std::greater<std::array<int, 3> > >::value_type&&' {aka 'std::array<int, 3>&&'}
648 | push(value_type&& __x)
| ~~~~~~~~~~~~~^~~
portal.cpp:88:38: warning: structured bindings only available with '-std=c++17' or '-std=gnu++17'
88 | auto [qx, qy] = go[x][y][port1];
| ^
portal.cpp:88:49: error: 'go' was not declared in this scope
88 | auto [qx, qy] = go[x][y][port1];
| ^~
portal.cpp:89:38: warning: structured bindings only available with '-std=c++17' or '-std=gnu++17'
89 | auto [wx, wy] = go[x][y][port2];
| ^
portal.cpp:90:115: error: no matching function for call to 'std::priority_queue<std::array<int, 3>, std::vector<std::array<int, 3> >, std::greater<std::array<int, 3> > >::push(<brace-enclosed initializer list>)'
90 | if (umin(d[wx][wy], d[x][y] + dist(x, y, qx, qy) + 1)) pq.push({d[wx][wy], wx, wy});
| ^
In file included from /usr/include/c++/10/queue:64,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:86,
from portal.cpp:1:
/usr/include/c++/10/bits/stl_queue.h:640:7: note: candidate: 'void std::priority_queue<_Tp, _Sequence, _Compare>::push(const value_type&) [with _Tp = std::array<int, 3>; _Sequence = std::vector<std::array<int, 3> >; _Compare = std::greater<std::array<int, 3> >; std::priority_queue<_Tp, _Sequence, _Compare>::value_type = std::array<int, 3>]'
640 | push(const value_type& __x)
| ^~~~
/usr/include/c++/10/bits/stl_queue.h:640:30: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'const value_type&' {aka 'const std::array<int, 3>&'}
640 | push(const value_type& __x)
| ~~~~~~~~~~~~~~~~~~^~~
/usr/include/c++/10/bits/stl_queue.h:648:7: note: candidate: 'void std::priority_queue<_Tp, _Sequence, _Compare>::push(std::priority_queue<_Tp, _Sequence, _Compare>::value_type&&) [with _Tp = std::array<int, 3>; _Sequence = std::vector<std::array<int, 3> >; _Compare = std::greater<std::array<int, 3> >; std::priority_queue<_Tp, _Sequence, _Compare>::value_type = std::array<int, 3>]'
648 | push(value_type&& __x)
| ^~~~
/usr/include/c++/10/bits/stl_queue.h:648:25: note: no known conversion for argument 1 from '<brace-enclosed initializer list>' to 'std::priority_queue<std::array<int, 3>, std::vector<std::array<int, 3> >, std::greater<std::array<int, 3> > >::value_type&&' {aka 'std::array<int, 3>&&'}
648 | push(value_type&& __x)
| ~~~~~~~~~~~~~^~~
portal.cpp:94:30: error: 'inf' was not declared in this scope; did you mean 'ynf'?
94 | if (d[f.fr][f.sc] == inf) cout << "nemoguce";
| ^~~
| ynf