submission_id stringlengths 10 10 | problem_id stringlengths 6 6 | language stringclasses 3
values | code stringlengths 1 522k | compiler_output stringlengths 43 10.2k |
|---|---|---|---|---|
s856268833 | p03768 | C++ | #include <bits/stdc++.h>
#define l_ength size
const int inf = (1<<30);
const int mod = 1000000007; // 998244353
using ll = long long;
using namespace std;
struct query{
int vert;
int dist;
int col;
};
vector<int> graph[100010];
vector<query> ql;
// farbe[v] := 頂点 v は何色か?(初期値 0)
int farbe[100010];
// dmax[v] := 頂点 ... | a.cc: In function 'int main()':
a.cc:57:21: error: 'class std::queue<int>' has no member named 'insert'
57 | que.insert(q.vert);
| ^~~~~~
a.cc:60:37: error: 'class std::queue<int>' has no member named 'top'; did you mean 'pop'?
60 | int v = que.top... |
s983763975 | p03768 | C++ |
Home
Problem
Status
Contest
User
Group
Forum
Article
Logout
_52hz
Have Fun
Begin: 2019-11-02 07:00 CST
图论和简单数据结构
End: 2019-11-05 07:00 CST
28:37:50
Elapsed: 28:37:50
Running
Remaining: 43:22:09
Overview
Problem
Status
Rank (28:37:45)
1 Comments
Rank
Team
... | a.cc:21:18: error: invalid digit "9" in octal constant
21 | Remaining: 43:22:09
| ^~
a.cc:65:25: error: invalid digit "8" in octal constant
65 | 6 1953 08:09:28
| ^~
a.cc:65:28: error: invalid digit "9" in octal constant
65 | 6 ... |
s069175515 | p03768 | C | #include<bits/stdc++.h>
using namespace std;
inline int read(int &a){a=0;int f=1;char c=getchar();
for(;c<'0'||c>'9';c=getchar())if(c=='-')f=-1;
for(;c<='9' && c>='0';a=a*10+c-'0',c=getchar());return a*=f;}
inline void print(int a){int s[20],t=0;if(!a){putchar('0');putchar('\n');return;}
while(a){s[t++]=a%10,a/=10;}for... | main.c:1:9: fatal error: bits/stdc++.h: No such file or directory
1 | #include<bits/stdc++.h>
| ^~~~~~~~~~~~~~~
compilation terminated.
|
s547919112 | p03768 | C++ | ok.
reverse order.
Remember the radius at each vertex while searching.
Then, it is guaranteed that an edge is visited at most 10 times.
| a.cc:1:1: error: 'ok' does not name a type
1 | ok.
| ^~
|
s494688878 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int,int> Pii;
typedef pair<ll,ll> Pll;
#define rep(i,n) for (ll i=0;i<n;++i)
#define rep2(i,a,b) for (ll i=a;i<b;++i)
const ll MOD=1000000007;
struct point{int start,rest,color;};
template<class T> inline bool chmin(T &a,T b){
if (a>b... | a.cc: In function 'int main()':
a.cc:48:42: warning: narrowing conversion of 'v.std::vector<long long int>::operator[](((std::vector<long long int>::size_type)i))' from '__gnu_cxx::__alloc_traits<std::allocator<long long int>, long long int>::value_type' {aka 'long long int'} to 'int' [-Wnarrowing]
48 | ... |
s058663225 | p03768 | C++ | bool done[100010][15];
void f(int v,int d,int c)
{
if(done[v][d]) return;
done[v][d]=true;
if(colour[v]==0) colour[v]=c;
if(d==0) return;
for(int i=0;i<edge[v].size();i++)
{
int to=edge[v][i];
f(to,d-1,c);
}
} | a.cc: In function 'void f(int, int, int)':
a.cc:7:8: error: 'colour' was not declared in this scope
7 | if(colour[v]==0) colour[v]=c;
| ^~~~~~
a.cc:9:19: error: 'edge' was not declared in this scope
9 | for(int i=0;i<edge[v].size();i++)
| ^~~~
|
s775912845 | p03768 | C++ | #include <bits/stdc++.h>
#define REP(i,n) for(int i=0;i<n;i++)
#define REPP(i,n) for(int i=1;i<=n;i++)
const double PI = acos(-1);
const double EPS = 1e-15;
long long INF=(long long)1E17;
#define i_7 (long long)(1E9+7)
long mod(long a){
long long c=a%i_7;
if(c>=0)return c;
return c+i_7;
}
using namespace st... | a.cc: In function 'int main()':
a.cc:129:16: error: invalid types 'int[int]' for array subscript
129 | dfs(v[i], q[i], c[i]);
| ^
|
s668303698 | p03768 | C++ | 14 10
1 4
5 7
7 11
4 10
14 7
14 3
6 14
8 11
5 13
8 3
8
8 6 2
9 7 85
6 9 3
6 7 5
10 3 1
12 9 4
9 6 6
8 2 3 | a.cc:1:1: error: expected unqualified-id before numeric constant
1 | 14 10
| ^~
|
s994202664 | p03768 | C++ | 14 10
1 4
5 7
7 11
4 10
14 7
14 3
6 14
8 11
5 13
8 3
8
8 6 2
9 7 85
6 9 3
6 7 5
10 3 1
12 9 4
9 6 6
8 2 3 | a.cc:1:1: error: expected unqualified-id before numeric constant
1 | 14 10
| ^~
|
s964827210 | p03768 | C++ | #include<iostream>
#include<vector>
#include<set>
#include<queue>
#include<map>
#include<algorithm>
#include<cstring>
#include<string>
#include<cassert>
#include<cmath>
#include<climits>
#include<iomanip>
using namespace std;
#define MOD 1000000007
#define REP(i,n) for(int (i)=0;(i)<(n);(i)++)
#define FOR(i,c) for(decl... | a.cc: In function 'int main()':
a.cc:212:59: error: 'used' was not declared in this scope
212 | dfs(graph, v[q - i - 1], d[q - i - 1], i, used);
| ^~~~
a.cc: In function 'long long int dfs(Graph&, long long int, long long int, long long i... |
s103081874 | p03768 | C++ |
using namespace std;
int N, M, Q, a[100005], b[100005], v[100005],c[100005],d[100005];
vector<int> Adj[100005];
int q[100005];
int dis[100005];
/*int D_base;
int query_num;
void INIT(int K, int D) {
dis[K] = D;
if ((q[K] > 0) && ( D_base - dis[K] <= d[q[K]])) {
if (query_num < q[K]) { query_num = q[K]; }
}... | a.cc:6:1: error: 'vector' does not name a type
6 | vector<int> Adj[100005];
| ^~~~~~
a.cc: In function 'void FUNC(int, int, int)':
a.cc:60:34: error: 'Adj' was not declared in this scope
60 | for (int u = 0; u < (int)Adj[V].size(); u++) {
| ^~~
a.cc: In functi... |
s749470000 | p03768 | C++ | #include<iostream> #include<iomanip> #include<algorithm> #include<cstring> #include<string> #include<cmath> #include<vector> #include<queue> #include<stack> #include<map> #include<set> using namespace std; const int inf=2147483647,dx[]={-1,0,1,0},dy[]={0,-1,0,1}; const long long llinf=9223372036854775807ll; const int N... | a.cc:1:20: warning: extra tokens at end of #include directive
1 | #include<iostream> #include<iomanip> #include<algorithm> #include<cstring> #include<string> #include<cmath> #include<vector> #include<queue> #include<stack> #include<map> #include<set> using namespace std; const int inf=2147483647,dx[]={-1,0,1,0},dy[... |
s489182979 | p03768 | C++ | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <cfloat>
#include <climits>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <queue>
#include <sstream>
#include <stack>
#include <time.h>
#include <vector>
#include <complex>
#include <map>
#include <set>
#include <iomanip>
#include <ma... | a.cc: In function 'int main()':
a.cc:44:30: error: expected primary-expression before ')' token
44 | for (int i=0;i<m;i+++){
| ^
|
s080869189 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
int n,m,q,i,j,vt[100005],d[100005],c[100005],dp[100005],col[100005]
vector <int> g[100005];
void dfs(int v,int d,int c)
{
if (!col[v]) col[v]=c;
if (dp[v]>=d || d==0) return;
dp[v]=d;for (int i=0;i<g[v].size();++i)
dfs(g[v][i],d-1,c);
}
int main()
{
cin>>n>>m;
for (i... | a.cc:4:1: error: expected initializer before 'vector'
4 | vector <int> g[100005];
| ^~~~~~
a.cc: In function 'void dfs(int, int, int)':
a.cc:7:14: error: 'col' was not declared in this scope; did you mean 'cosl'?
7 | if (!col[v]) col[v]=c;
| ^~~
| cosl
a.cc:9:... |
s336380830 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
int n,m,q,i,j,vt[100005],d[100005],c[100005],dp[100005],col[100005]
vector <int> g[100005];
void dfs(int v,int d,int c)
{
if (!col[v]) col[v]=c;
if (dp[v]>=d || d==0) return;
dp[v]=d;for (i=0;i<g[v].size();++i)
dfs(g[v][i],d-1,c);
}
int main()
{
cin>>n>>m;
for (i=0;i... | a.cc:4:1: error: expected initializer before 'vector'
4 | vector <int> g[100005];
| ^~~~~~
a.cc: In function 'void dfs(int, int, int)':
a.cc:7:14: error: 'col' was not declared in this scope; did you mean 'cosl'?
7 | if (!col[v]) col[v]=c;
| ^~~
| cosl
a.cc:9:... |
s892156508 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
int main()
{
int n,m;
cin>>n>>m;
int a[10];
for(int i=0;i<10;i++)
{
for(int j=0;j<10;j+10)
{
for(int k=0;k<10;k++)
{
cin>>a[k];
cout<<a[k];
}
}
}
cout<<"d... | a.cc: In function 'int main()':
a.cc:19:30: error: expected ';' before 'return'
19 | cout<<"defineansiloveccs"
| ^
| ;
20 | return 0;
| ~~~~~~
|
s555291333 | p03768 | C++ | #include<bits/stdc++.h>
using namespace std;
int v[100001],c[100001],d[100001];
int dis[100001];
int co[100001];
int now;
vector<int> g[100001];
void bfs(){
queue<int> q;
q.push(v[now]);
dis[v[now]]=0;
while(!q.empty()){
int ths=q.front();
q.pop();
if(dis[ths]>d[now])
... | a.cc: In function 'void bfs()':
a.cc:23:48: error: 'n' was not declared in this scope
23 | if(co[g[ths][i]] && dis[ths]+2>n)
| ^
|
s376634540 | p03768 | C++ | //**************************
//*** writer : Alex Hu **
//************************
#include<bits/stdc++.h>
using namespace std;
#define CLEAN(a,b) memset(a,b,sizeof(a))
#define mkp make_pair
#define pb push_back
#define rept(i,a,b) for(int i=(int)(a);i<(int)(b);i++)
typedef long long ll;
typedef pair<int, int> pii... | a.cc: In function 'void dfs(int)':
a.cc:43:14: error: 'g' was not declared in this scope
43 | rept(i,0,g[x].size())
| ^
a.cc:12:48: note: in definition of macro 'rept'
12 | #define rept(i,a,b) for(int i=(int)(a);i<(int)(b);i++)
| ^
a.cc: ... |
s750977818 | p03768 | C++ | #include <bits/stdc++.h>
#define pb push_back
#define mp make_pair
#define all(x) (x).begin(), (x).end()
#define fi first
#define se second
using namespace std;
typedef long long ll;
const int MAXN = (int)1e5 + 5;
struct que {
int v, d, col;
que() {
v = d = col = 0;
}
} req[MAXN];
... | a.cc: In function 'void solve()':
a.cc:93:16: error: return-statement with a value, in function returning 'void' [-fpermissive]
93 | return 0;
| ^
|
s584885623 | p03768 | C++ | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <cfloat>
#include <climits>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <queue>
#include <sstream>
#include <stack>
#include <time.h>
#include <vector>
#include <complex>
#include <map>
#include <set>
#include <iomanip>
#include <ma... | a.cc: In function 'void bfs(int, int, int)':
a.cc:48:37: error: expected primary-expression before ')' token
48 | if ()q.push(n);
| ^
|
s078891193 | p03768 | C++ | #include <cstdio>
#include <cstdlib>
#include <iostream>
#include <fstream>
#include <sstream>
#include <set>
#include <map>
#include <vector>
#include <list>
#include <algorithm>
#include <cstring>
#include <cmath>
#include <string>
#include <queue>
#include <bitset> //UWAGA - w czasie kompilacji musi byc znany ro... | a.cc: In function 'int main()':
a.cc:22:20: error: expected unqualified-id before 'for'
22 | #define FOR(i,b,e) for(int i=(b);i<(e);++i)
| ^~~
a.cc:50:9: note: in expansion of macro 'FOR'
50 | FOR(i,0,q)cin>>v[i]>>d[i]>>c[i];
| ^~~
a.cc:50:13: error: 'i' was not decl... |
s426039158 | p03768 | C++ | //waz
#include <bits/stdc++.h>
using namespace std;
#define mp make_pair
#define pb push_back
#define fi first
#define se second
#define ALL(x) (x).begin(), (x).end()
#define SZ(x) ((int)((x).size()))
typedef pair<int, int> PII;
typedef vector<int> VI;
typedef long long int64;
typedef unsigned int uint;
typedef unsi... | a.cc: In function 'void dfs(int, int, int)':
a.cc:49:19: error: expected unqualified-id before ':' token
49 | for (auto : edge[u])
| ^
a.cc:50:21: error: 'v' was not declared in this scope
50 | dfs(v, d - 1, c);
| ^
|
s836945617 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
const int MAXN = 100000 + 10;
typedef long long ll;
vector<int> q[MAXN];
int color[MAXN];
int flag[MAXN];
int n, m, q;
int v[MAXN], d[MAXN], c[MAXN];
void dfs(int x, int cnt, int c)
{
if (!color[x])
color[x] = c;
if (flag[x] >= cnt)
return;
if (cnt == 0)
return;
... | a.cc:9:11: error: conflicting declaration 'int q'
9 | int n, m, q;
| ^
a.cc:6:13: note: previous declaration as 'std::vector<int> q [100010]'
6 | vector<int> q[MAXN];
| ^
a.cc: In function 'int main()':
a.cc:36:13: error: no match for 'operator>>' (operand types are 'std::istre... |
s499850668 | p03768 | C++ | #include <algorithm>
#include <iostream>
#include <vector>
#include <math.h>
#include <set>
#include <map>
#include <string>
#include <stack>
#include <queue>
#include <iomanip>
#include <numeric>
#include <tuple>
#include <bitset>
#include <complex>
#define _USE_MATH_DEFINES
using namespace std;
typedef long long ll;
... | a.cc:40:16: error: conflicting declaration 'int d [200000]'
40 | int v[200000], d[200000], c[200000];
| ^
a.cc:39:4: note: previous declaration as 'll d [3000][3000]'
39 | ll d[3000][3000];
| ^
a.cc: In function 'int main()':
a.cc:82:21: error: no match for 'operator>>' (operand type... |
s728947236 | p03768 | C++ | 14 10
1 4
5 7
7 11
4 10
14 7
14 3
6 14
8 11
5 13
8 3
8
8 6 2
9 7 85
6 9 3
6 7 5
10 3 1
12 9 4
9 6 6
8 2 3
| a.cc:1:1: error: expected unqualified-id before numeric constant
1 | 14 10
| ^~
|
s195213674 | p03768 | C++ | #include <bits/stdc++.h>
//#include <math.h>
using namespace std;
#define INF 1.1e9
#define LINF 1.1e18
#define FOR(i,a,b) for (int i=(a);i<(b);++i)
#define REP(i,n) FOR(i,0,n)
#define ALL(v) (v).begin(),(v).end()
#define pb push_back
#define pf push_front
#define fi first
#define se second
#define BIT(x,n) bitset<n>(... | a.cc: In function 'int main()':
a.cc:47:22: error: 'v' was not declared in this scope
47 | cin>>v>>d>>c[i];
| ^
a.cc:47:25: error: 'd' was not declared in this scope
47 | cin>>v>>d>>c[i];
| ^
|
s795611003 | p03768 | C++ | #include<cstdio>
#include<algorithm>
#include<cstring>
#define maxn 200050
#define add(u,v)(to[++top]=head[u],head[u]=top,w[top]=v)
#define For(x) for (int h=head[x],o=w[h];h;o=w[h=to[h]])
using namespace std;
int n,m,to[maxn],head[maxn],w[maxn],u,v,top;
int a[maxn],b[maxn],c[maxn],co[maxn],r[maxn],q,i;
void dfs(in... | a.cc: In function 'int main()':
a.cc:29:9: error: 'memeset' was not declared in this scope; did you mean 'memset'?
29 | memeset(co,0,sizeof(co));memset(r,0,sizeof(r));
| ^~~~~~~
| memset
|
s372006847 | p03768 | C++ | #include<cstdio>
using namespace std;
const int N=100000+5;
int n, m;
int d[N], v[N], c[N];
int cnt, first[N], to[2*N], next[2*N];
void add(int u, int v) {
to[++cnt]=v; next[cnt]=first[u]; first[u]=cnt;
to[++cnt]=u; next[cnt]=first[v]; first[v]=cnt;
}
int col[N], mark[N];
void work(int now, int len, int color) {
... | a.cc: In function 'int main()':
a.cc:31:37: error: too many arguments to function 'void work(int, int, int)'
31 | for(int i=Q; i>=1; i--) work(v[i], 0, d[i], c[i]);
| ~~~~^~~~~~~~~~~~~~~~~~~~~
a.cc:16:6: note: declared here
16 | void work(int now, int len, int color) ... |
s303217541 | p03768 | C++ | /*
ID: 5ak0
PROG:
LANG: C++11
*/
#include <bits/stdc++.h>
#define fr first
#define sc second
#define pb push_back
#define mpr make_pair
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
const int INF = 1e9 + 7, MAXN = 1e5 + 10, MAXD = 11;
int n, m, q;
int c[MAXN], v, d;
vector <int> g[MAXN];
in... | a.cc: In function 'int main()':
a.cc:44:40: error: 'e' was not declared in this scope
44 | for (auto to : e[j]){
| ^
|
s262966734 | p03768 | C++ | #include <cstdio>
#include <cstring>
#include <cstdlib>
#include <vector>
#include <algorithm>
using namespace std;
struct node {
int color;
int next[100001];
int nextnum = 0;
};
int n, m, q;
struct node Node[100001];
int visit[100001];
void color (int v, int d, int c) {
Node[v].color = c;
int i ... | /tmp/cceP1Gjn.o: in function `color(int, int, int)':
a.cc:(.text+0x40): relocation truncated to fit: R_X86_64_PC32 against symbol `visit' defined in .bss section in /tmp/cceP1Gjn.o
a.cc:(.text+0x145): relocation truncated to fit: R_X86_64_PC32 against symbol `visit' defined in .bss section in /tmp/cceP1Gjn.o
/tmp/cceP1... |
s465682856 | p03768 | C++ | #include <cstdio>
#include <cstring>
#include <cstdlib>
#include <vector>
#include <algorithm>
using namespace std;
struct node {
int color;
int next[100001];
int nextnum = 0;
};
int n, m, q;
struct node Node[100001];
int visit[100001];
void color (int v, int d, int c) {
Node[v].color = c;
int i ... | /tmp/ccfzPHTA.o: in function `color(int, int, int)':
a.cc:(.text+0x40): relocation truncated to fit: R_X86_64_PC32 against symbol `visit' defined in .bss section in /tmp/ccfzPHTA.o
a.cc:(.text+0x145): relocation truncated to fit: R_X86_64_PC32 against symbol `visit' defined in .bss section in /tmp/ccfzPHTA.o
/tmp/ccfzP... |
s714577926 | p03768 | C++ | #include <cstdio>
#include <cstring>
#include <cstdlib>
#include <vector>
#include <algorithm>
using namespace std;
struct node {
int color;
int next[100001];
int nextnum = 0;
};
int n, m, q;
struct node Node[100001];
int visit[100001];
void color (int v, int d, int c) {
Node[v].color = c;
int i ... | /tmp/ccmqBCjR.o: in function `color(int, int, int)':
a.cc:(.text+0x40): relocation truncated to fit: R_X86_64_PC32 against symbol `visit' defined in .bss section in /tmp/ccmqBCjR.o
a.cc:(.text+0x145): relocation truncated to fit: R_X86_64_PC32 against symbol `visit' defined in .bss section in /tmp/ccmqBCjR.o
/tmp/ccmqB... |
s443695670 | p03768 | C++ | #include <cstdio>
#include <cstring>
#include <cstdlib>
#include <vector>
#include <algorithm>
using namespace std;
struct node {
int color;
int next[100001];
int nextnum = 0;
};
int n, m, q;
struct node Node[100001];
int visit[100001];
void color (int v, int d, int c) {
Node[v].color = c;
int i ... | /tmp/ccOtTc4T.o: in function `color(int, int, int)':
a.cc:(.text+0x40): relocation truncated to fit: R_X86_64_PC32 against symbol `visit' defined in .bss section in /tmp/ccOtTc4T.o
a.cc:(.text+0x145): relocation truncated to fit: R_X86_64_PC32 against symbol `visit' defined in .bss section in /tmp/ccOtTc4T.o
/tmp/ccOtT... |
s315219774 | p03768 | C++ | #include <vector>
#include <algorithm>
#include <queue>
using namespace std;
int n,m,q;
int dp[10][100001];
int d[100001],c[100001],v[100001];
vector<int> G[100001];
void f(int ver,int dist,int color){
//printf("%d %d %d\n",ver,dist,color);
if(dist<0)return ;
if(dp[dist][ver]!=0)return ;
dp[dist][ver]=color... | a.cc: In function 'int main()':
a.cc:25:3: error: 'cin' was not declared in this scope
25 | cin >> n >> m;
| ^~~
a.cc:4:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
3 | #include <queue>
+++ |+#include <iostream>
4 | using namespac... |
s406196365 | p03768 | C++ | #include <iostream>
#include <vector>
#include <cmath>
#include <map>
#include <string>
#include <algorithm>
#include <climits>
#include <set>
#include <queue>
#include <unordered_set>
using namespace std;
#define ll long long
struct Question
{
int v;
int d;
int c;
};
class Solver
{
public:
int n;
int m;
int ... | a.cc: In constructor 'Solver::Solver()':
a.cc:41:22: error: expected ';' before 'for'
41 | adj.resize(n)
| ^
| ;
42 | for (int i = 0; i < m; ++i)
| ~~~
a.cc:42:25: error: 'i' was not declared in this scope
42 | ... |
s824565791 | p03768 | Java | import java.math.BigInteger;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.Scanner;
public class Main {
public Main() {
// TODO Auto-generated constructor stub
}
public static void main(String[] args) {
SplatterPainting sp = new Spla... | Main.java:84: error: class, interface, enum, or record expected
}
^
1 error
|
s316434459 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
#define for_(i,a,b) for(int i=(a);i<(b);++i)
void solve(int N, int M, const vector< vector< int > >& edge) {
int Q;
cin >> Q;
typedef pair< int, int > pii;
vector< vector< int > > last_paint(N, vector< int >(11, pii));
for_(q,0,Q) {
int v, d, c;
cin >> v >> ... | a.cc: In function 'void solve(int, int, const std::vector<std::vector<int> >&)':
a.cc:12:60: error: expected primary-expression before '(' token
12 | vector< vector< int > > last_paint(N, vector< int >(11, pii));
| ^
a.cc:12:68: error: expected... |
s508051438 | p03768 | C++ | //It is made by ljh2000
//有志者,事竟成,破釜沉舟,百二秦关终属楚;苦心人,天不负,卧薪尝胆,三千越甲可吞吴。
#include <algorithm>
#include <iostream>
#include <cstring>
#include <vector>
#include <cstdio>
#include <string>
#include <queue>
#include <cmath>
#include <ctime>
using namespace std;
typedef long long LL;
const int MAXN = 100011;
const int MAXM = 2... | a.cc: In function 'void link(int, int)':
a.cc:18:32: error: reference to 'next' is ambiguous
18 | inline void link(int x,int y){ next[++ecnt]=first[x]; first[x]=ecnt; to[ecnt]=y; }
| ^~~~
In file included from /usr/include/c++/14/bits/stl_algobase.h:66,
from /usr... |
s435738048 | p03768 | C++ | #include<iostream>
#include<stack>
using namespace std;
static const int N = 100001;
int n, m,q,color[N];
void dfs(int v,int d,int c) {
color[v]=c;
if(d==0) return;
d--;
for(int i=1;i<=n;i++){
if(M[v][i]==1||M[i][v]==1){
dfs(i,d,c);
}
}
for(int i=1;i<=n;i++){
//ぬる
}
}
int main()
{... | a.cc: In function 'void dfs(int, int, int)':
a.cc:13:8: error: 'M' was not declared in this scope
13 | if(M[v][i]==1||M[i][v]==1){
| ^
a.cc: In function 'int main()':
a.cc:32:25: error: 'M' was not declared in this scope
32 | M[i][j] = 0;
| ^
... |
s287578756 | p03768 | C++ | #include<bits/stdc++.h>
#define INF 1e9+7
#define ll long long
#define F first
#define S second
#define N 100005
#define M 1000000009
#define mp make_pair
#define ull unsigned long long
#define sc(n) scanf("%d",&n)
#define gcd __gcd
#define pb push_back
using namespace std;
std::vector<int> v[N],jh;
stack<pair<int,pai... | a.cc: In function 'void line(int, int, int)':
a.cc:30:9: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
30 | int main(){
| ^~
a.cc:30:9: note: remove parentheses to default-initialize a variable
30 | int main(){
| ^~
| --
a.cc:30:... |
s613662118 | p03768 | C++ | //#pragma GCC optimize("O3")
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int N = (int) 1e5 + 5;
const int mod = (int) 1e9 + 7;
vector<int> g[N];
int n, m, q, ans[N], ds[N], od[N];
void paint (int v, int d, int c, int ood) {
if (ans[v] != 0 && ds[v] >= d) {
retu... | a.cc: In function 'void paint(int, int, int, int)':
a.cc:27:69: error: invalid types 'int[int]' for array subscript
27 | if (f && od[to] >= d && od[v] == od[to] && d[v] == d[to] - 1 && ans[v] == ans[to]) {
| ^
a.cc:27:7... |
s078920543 | p03768 | C++ | #include <iostream>
#include <queue>
#include <vector>
#include <cstdio>
#include <cstring>
using namespace std;
vector<int> adj[100001];
bool dp[100001][11];
int color[100001];
void dfs(int v,int d,int c){
if(color[v]==0) color[v]=c;
dp[v][d]=true;
for(int i=0;i<adj[v].size();i++){
int ne... | a.cc: In function 'int main(int, const char**)':
a.cc:40:27: error: 'v' was not declared in this scope
40 | scanf("%d %d %d",&v[i],&d[i],&c[i]);
| ^
a.cc:40:33: error: 'd' was not declared in this scope
40 | scanf("%d %d %d",&v[i],&d[i],&c[i]);
| ... |
s810452616 | p03768 | C | #include <stdio.h>
#define FOR(i,a,n) for(int i=a;i<n;i++)
int g[100000][100000];
int size[100000];
int color[100000];
int visited[100000];
int c,d;
void dfs(int v,int n){
color[v]=c;
if(n==d) return;
visited[v]=1;
FOR(i,0,size[v]){
if(!visited[g[v][i]]){
dfs(g[v][i],n+1);
}
... | /tmp/cciDbt6W.o: in function `dfs':
main.c:(.text+0x10): relocation truncated to fit: R_X86_64_PC32 against symbol `c' defined in .bss section in /tmp/cciDbt6W.o
main.c:(.text+0x25): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss section in /tmp/cciDbt6W.o
main.c:(.text+0x2e): relocat... |
s924422543 | p03768 | C++ | #include<cstdio>
#include <iostream>
#include<algorithm>
#include<string>
#include<cstring>
#include<queue>
#include<vector>
#include<functional>
#include<cmath>
#include<map>
#include<stack>
#include<cstdlib>
#include<list>
#include<set>
#include<numeric>
using namespace std;
typedef long long ll;
typedef pair<int, i... | a.cc: In function 'int main()':
a.cc:31:17: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
31 | scanf_s("%d %d",&a,&b);
| ^~~~~~~
| scanf
a.cc:40:17: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
40 | ... |
s221841382 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
typedef long long LL;
const int nmax = 100010; const LL mod = 1000003;
int N,M,c[nmax],lg[2005][2005],w,as[nmax];
vector<int>G[nmax];
void fct(int nod,tata,int d,int cul){
if(d >= 0&&!c[nod])c[nod] = cul;
if(!d) return;
for(auto it: G[nod])
if(it != tata)
... | a.cc:12:18: error: 'tata' has not been declared
12 | void fct(int nod,tata,int d,int cul){
| ^~~~
a.cc: In function 'void fct(int, int, int, int)':
a.cc:17:13: error: 'tata' was not declared in this scope
17 | if(it != tata)
| ^~~~
|
s743904559 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
typedef long long LL;
const int nmax = 100010; const LL mod = 1000003;
int N,M,c[nmax],lg[2005][2005],w,as[nmax];
vector<int>G[nmax];
void fct(int nod,,tata,int d,int cul){
if(d >= 0&&!c[nod])c[nod] = cul;
if(!d) return;
for(auto it: G[nod])
if(it != tata)... | a.cc:12:18: error: expected identifier before ',' token
12 | void fct(int nod,,tata,int d,int cul){
| ^
a.cc:12:19: error: 'tata' has not been declared
12 | void fct(int nod,,tata,int d,int cul){
| ^~~~
a.cc: In function 'void fct(int, int, int, int, int)':
a.cc:17:1... |
s773643916 | p03768 | C | #include <iostream>
#include <vector>
#define REP(i, a, n) for(int i = (a); i <= (n); i++)
using namespace std;
int N, M, Q, v[100001], d[100001], c[100001];
vector<int> E[100001];
int dp[11][100001];
void dfs(int v, int d, int c) {
dp[d][v] = c;
if(d == 0) return;
if(dp[d - 1][v] == 0) dfs(v, d - 1, c);
for(... | main.c:1:10: fatal error: iostream: No such file or directory
1 | #include <iostream>
| ^~~~~~~~~~
compilation terminated.
|
s962036995 | p03768 | C++ | #include <iostream>
#include <vector>
#include <cstdint>
using namespace std;
vector<int_least32_t> nodeColor;
vector< vector<int_least32_t>> map;
int paintNode(int_least32_t origin, int_least32_t range, int_least32_t color)
{
if(range == 0) {
return 0;
}
nodeColor[origin] = color;
for(auto& x : map[origin]) ... | a.cc: In function 'int paintNode(int_least32_t, int_least32_t, int_least32_t)':
a.cc:18:17: error: 'paintnode' was not declared in this scope; did you mean 'paintNode'?
18 | paintnode(x, range - 1, color);
| ^~~~~~~~~
| paintNode
a.cc: In function 'int main... |
s771573883 | p03768 | C++ | #include <iostream>
#include <vector>
#include <cstdint>
using namespace std;
vector<int_least32_t> nodeColor;
vector< vector<int_least32_t>> map;
int paintNode(int_least32_t origin, int_least32_t range, int_least32_t color)
{
if(range == 0) {
return 0;
}
nodeColor[origin] = color;
for(auto& x : map[origin]) ... | a.cc: In function 'int paintNode(int_least32_t, int_least32_t, int_least32_t)':
a.cc:18:17: error: 'paintnode' was not declared in this scope; did you mean 'paintNode'?
18 | paintnode(x, range - 1, color);
| ^~~~~~~~~
| paintNode
a.cc: In function 'int main... |
s827142362 | p03768 | C++ | #include <iostream>
#include <vector>
#include <cstdint>
using namespace std;
vector<int_least32_t> nodeColor;
vector< vector<int_least32_t>> map;
int paintNode(int_least32_t origin, int_least32_t range, int_least32_t color)
{
if(range == 0) {
return 0;
}
nodeColor[origin] = color;
for(auto& x : map[origin]) ... | a.cc: In function 'int paintNode(int_least32_t, int_least32_t, int_least32_t)':
a.cc:18:17: error: 'paintnode' was not declared in this scope; did you mean 'paintNode'?
18 | paintnode(x, range - 1, color);
| ^~~~~~~~~
| paintNode
a.cc: In function 'int main... |
s809751003 | p03768 | C++ | #include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
constexpr int MaxN = 100000 + 10;
constexpr int MaxD = 10;
int n, m, q;
vector<int> E[MaxN];
int C[MaxN];
int dp[MaxN][MaxD + 1];
void MaxAssign(int &a, int b) {
a = max(a, b);
}
int main() {
cin >> n >> m;
for (int i = 0; ... | a.cc: In function 'int main()':
a.cc:30:5: error: 'memset' was not declared in this scope
30 | memset(dp, -1, sizeof(dp) / sizeof(int));
| ^~~~~~
a.cc:4:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
3 | #include <algorithm>
+++ |+#incl... |
s355344397 | p03768 | Java | import java.util.ArrayList;
import java.util.Scanner;
public class B {
static Scanner scan = new Scanner(System.in);
static int N = scan.nextInt();
static int M = scan.nextInt();
static int dp[][]=new int[N][N];
static int count;
public static void paint(int v,int c,V vs[]){
if(count<0){return;}//探索が奥まで行ったら終... | Main.java:4: error: class B is public, should be declared in a file named B.java
public class B {
^
1 error
|
s355453917 | p03768 | Java | import java.util.*;
public class Main{
public static void main(String[] args){
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int m = sc.nextInt();
int[] a = new int[2*m];
int[] b = new int[2*m];
int[] color = new int[n];
int[][] dist = new int[n][n];
for(int i=0;i<n;i++){
color[i] = 0... | Main.java:36: error: illegal start of type
while(changed){
^
Main.java:36: error: <identifier> expected
while(changed){
^
Main.java:66: error: illegal start of type
for(int i=0; i<q; i++){
^
Main.java:66: error: > or ',' expected
for(int i=0; i<q; i++){
^
Main.java:66: error... |
s050672878 | p03768 | C++ | a | a.cc:1:1: error: 'a' does not name a type
1 | a
| ^
|
s771573968 | p03768 | C++ | //部分点が狙えるかも、また、枝刈りで通ればいいなあ
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define Rep(i, N) for(int i = 0; i < N; i++)
#define pb push_back
typedef pair<int, int> Pi;
typedef pair<Pi, Pi> Ti;
#define fi first
#define se second
vector < int > G[100005];
int color[100005] = {0};
int power[100005]... | a.cc: In function 'void bfs()':
a.cc:35:43: error: expected ')' before ';' token
35 | pq.push(Ti(Pi(u, d - 1), Pi(p, c));
| ~ ^
| )
a.cc: In function 'int main()':
a.cc:56:7: error: conflicting declaration 'long lon... |
s643506243 | p03768 | C++ | #include <cstdio>
#include <algorithm>
#include <stack>
#include <queue>
#include <deque>
#include <vector>
#include <string>
#include <string.h>
#include <cstdlib>
#include <ctime>
#include <cmath>
#include <map>
#include <set>
#include <iostream>
#include <sstream>
#include <numeric>
#include <cctype>
#include <bitse... | a.cc:181:12: error: redefinition of 'int in()'
181 | inline int in() { int x; scanf("%d",&x); return x;}
| ^~
a.cc:50:12: note: 'int in()' previously defined here
50 | inline int in() { int x; scanf("%d",&x); return x;}
| ^~
a.cc:182:13: error: redefinition of 'void priv(vi)'
18... |
s355041037 | p03768 | C++ | #include<cstdio>
#include<cstdlib>
#include<cmath>
#include<string>
#include<queue>
#include<vector>
#include<map>
#include<algorithm>
#define rep(n) for(int i=0;i<n;i++)
#define repp(j, n) for(int j=0;j<n;j++)
#define reppp(i, m, n) for(int i=m;i<=n;i++)
#define all(c) c.begin(), c.end()
#define rall(c) c.rbegin(), c... | a.cc:21:9: error: 'pair' does not name a type
21 | typedef pair<ll, ll> P;
| ^~~~
a.cc:24:1: error: 'vector' does not name a type
24 | vector<ll> es[1000000];
| ^~~~~~
a.cc:25:1: error: 'vector' does not name a type
25 | vector<ll> color(1000000, 0);
| ^~~~~~
a.cc:28:27: error: 'vecto... |
s166724481 | p03768 | C++ | #include <iostream>
#include <vector>
using namespace std;
const int N = 100000;
int n, m, q, color[N], a[N], b[N], v[N], d[N], c[N], used[N];
vector <vector<int>>mat(N, vector<int>(N));
void use(int node, int length, int c) {
if (length == 0)return;
used[node] = 1;
for (int i = 0; i < mat[node].size(); i++) {
i... | a.cc: In function 'void use(int, int, int)':
a.cc:13:37: error: too few arguments to function 'void use(int, int, int)'
13 | if (used[i] == 0)use(i, length - 1);
| ~~~^~~~~~~~~~~~~~~
a.cc:9:6: note: declared here
9 | void use(int node, int length, int c) {
... |
s715335583 | p03768 | C | #include <iostream>
#include <algorithm>
#include <set>
#include <array>
using namespace std;
int n, m, q;
int v[100000], d[100000], c[100000];
array< array< set<int>, 100000> , 11> dp;
int main() {
cin >> n >> m;
for(int i = 0; i < n; i++) {
dp[0][i].insert(i);
dp[1][i].insert(i);
}
for (int i = 0; ... | main.c:1:10: fatal error: iostream: No such file or directory
1 | #include <iostream>
| ^~~~~~~~~~
compilation terminated.
|
s827554305 | p03768 | C++ | #include<cstdio>
#include<cstring>
#include<cmath>
#include<algorithm>
#include<queue>
#include<vector>
const int MaxN = 1e5;
using namespace std;
int vis[MaxN + 5][MaxN + 5] , dis[MaxN + 5][MaxN + 5];
int ans[MaxN + 5] , n , m , T;
queue<int>que;
vector<int>G[MaxN + 5];
void Init(){
memset(vis , 0 , sizeof(vis));
me... | /tmp/ccGyhThR.o: in function `Init()':
a.cc:(.text+0x36): relocation truncated to fit: R_X86_64_PC32 against symbol `ans' defined in .bss section in /tmp/ccGyhThR.o
a.cc:(.text+0x74): relocation truncated to fit: R_X86_64_PC32 against symbol `dis' defined in .bss section in /tmp/ccGyhThR.o
a.cc:(.text+0xb8): relocation... |
s044046219 | p03768 | Java | import java.util.Scanner;
public class B {
static Scanner scan = new Scanner(System.in);
static int N = scan.nextInt();
static int M = scan.nextInt();
static int dp[][]=new int[N][N];
static int count;
static int color[]=new int[N];
public static void paint(int v,int c){
if(count<0){return;}
for(int j=0;j... | Main.java:3: error: class B is public, should be declared in a file named B.java
public class B {
^
1 error
|
s007724602 | p03768 | C++ | #include <iostream>
#include <array>
#include <vector>
#include <list>
#include <stack>
#include <queue>
#include <set>
#include <map>
#include <unordered_set>
#include <unordered_map>
#include <algorithm>
#include <string>
#include <sstream>
#include <memory>
#include <cassert>
#include <functional>
#include <chro... | a.cc: In member function 'void ValLib::udvgraph::doActionSub(int, int, int)':
a.cc:656:63: error: expected ']' before ')' token
656 | if (check[egde.second->getID()) {
| ^
|
s951606608 | p03768 | C++ | #include <iostream>
#include <cstdio>
#include <vector>
#include <cmath>
#include <cstring>
#include <numeric>
#include <algorithm>
#include <functional>
#include <array>
#include <map>
#include <queue>
#include <limits.h>
#include <set>
#include <stack>
#include <random>
#include <complex>
#include <unordered_map>
#de... | a.cc: In lambda function:
a.cc:150:41: error: '__gnu_cxx::__alloc_traits<std::allocator<std::vector<int> >, std::vector<int> >::value_type' {aka 'class std::vector<int>'} has no member named 'push_aback'; did you mean 'push_back'?
150 | mat[qn].push_aback(itr.first);
| ... |
s898080504 | p03768 | Java | import java.util.Scanner;
public class B {
static Scanner scan = new Scanner(System.in);
static int N = scan.nextInt();
static int M = scan.nextInt();
static int dp[][]=new int[N][N];
static int count;
static int color[]=new int[N];
public static void paint(int v,int c){
if(count<0){return;}
for(int j=0;j... | Main.java:3: error: class B is public, should be declared in a file named B.java
public class B {
^
1 error
|
s954163252 | p03768 | C++ | #include<iostream>
#include<algorithm>
#include<vector>
#include<queue>
using namespace std;
#define REP(i, a, n) for(int i=a; i<n; i++)
#define ll long long
bool grid[2001][2001] = {};
int main()
{
int N, M, Q;
int v[2001], d[2001], c[2001], color[2001];
cin >> N >> M;
REP(i, 1, M+1) {
int x, y;
cin >> x >> ... | a.cc: In function 'int main()':
a.cc:23:9: error: 'memset' was not declared in this scope
23 | memset(color, 0, sizeof color);
| ^~~~~~
a.cc:5:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
4 | #include<queue>
+++ |+#include <cs... |
s522904203 | p03768 | C++ | #include<stdio.h>
#include<vector>
#include<queue>
#define getchar_unlocked getchar
#define putchar_unlocked putchar
#define rep(i,n)for(int i=0;i<(n);i++)
#define MOD 1000000007
#define INF 0x3f3f3f3f
#define INFL 0x3f3f3f3f3f3f3f3f
#define EPS (1e-10)
using namespace std;
typedef long long ll;
typedef pair<int, int>P... | a.cc: In function 'void reader(int*)':
a.cc:18:56: error: 'mygc' was not declared in this scope
18 | void reader(int *x) { int k, m = 0; *x = 0; for (;;) { mygc(k); if (k == '-') { m = 1; break; }if ('0' <= k&&k <= '9') { *x = k - '0'; break; } }for (;;) { mygc(k); if (k<'0' || k>'9')break; *x = (*x) * 10 + k - '0';... |
s503851325 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
#define pb push_back
#define mp make_pair
typedef pair<int,int> pii;
#define Y second
#define FOR(x,e,b) (int e = head[x], b = vb[e]; e; e = nxt[e], b = vb[e])
#define N 200010
int n,m,q;
pii ans[N][11];
int M = 0, head[N], vb[N], nxt[N], vc[N];
void ins(int a,int b)
{
nx... | a.cc: In function 'int main()':
a.cc:7:21: error: expected primary-expression before 'int'
7 | #define FOR(x,e,b) (int e = head[x], b = vb[e]; e; e = nxt[e], b = vb[e])
| ^~~
a.cc:57:25: note: in expansion of macro 'FOR'
57 | FOR(j, e, b)
| ... |
s430084409 | p03768 | C++ | #include <bits/stdc++.h>
using namespace std;
#define pb push_back
#define mp make_pair
typedef pair<int,int> pii;
#define Y second
#define esb(x,e,b) (int e = head[x], b = vb[e]; e; e = nxt[e], b = vb[e])
#define N 200010
int n,m,q;
pii ans[N][11];
int M = 0, head[N], vb[N], nxt[N], vc[N];
void ins(int a,int b)
{
nx... | a.cc: In function 'int main()':
a.cc:57:32: error: 'e' was not declared in this scope
57 | FOR(j, e, b)
| ^
a.cc:57:35: error: 'b' was not declared in this scope
57 | FOR(j, e, b)
| ^
a.cc:... |
s523947310 | p03768 | C++ | #include <iostream>
#include <queue>
#include <vector>
#include <cstdio>
using namespace std;
vector<int> adj[2001];
int v[2001];
int d[2001];
int c[2001];
int check[2001];
int ans[2001];
void bfs(int i,int limit,int color){
memset(check,-1,sizeof(check));
check[i]=0;
ans[i]=color;
queue<int> ... | a.cc: In function 'void bfs(int, int, int)':
a.cc:14:5: error: 'memset' was not declared in this scope
14 | memset(check,-1,sizeof(check));
| ^~~~~~
a.cc:5:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
4 | #include <cstdio>
+++ |+#incl... |
s992555507 | p03768 | C++ | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <map>
#include <cmath>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <vector>
#include <stdlib.h>
#include <stdio.h>
using namespace std;
#define ll long long
#define PI acos(-1.0)
#defi... | a.cc: In function 'int main()':
a.cc:67:17: error: too few arguments to function 'void dijkstra(int, int, int)'
67 | dijkstra(v);
| ~~~~~~~~^~~
a.cc:28:6: note: declared here
28 | void dijkstra(int s, int dd, int c){
| ^~~~~~~~
|
s816429131 | p03768 | Java | import java.util.Scanner;
import java.io.*;
import java.util.*;
import java.math.*;
import java.lang.*;
import static java.lang.Math.*;
public class Main
{
static class InputReader
{
private InputStream stream;
private byte[] buf = new byte[1024];
private int curChar;
private int numChars;
private SpaceCh... | Main.java:189: error: invalid method declaration; return type required
public Check2(int n){
^
1 error
|
s673271664 | p03768 | Java | import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Scanner;
public class A{
static final Scanner s =new Scanner(System.in);
static int n, m, q;
static boolean checked[];
static Node nodes[];
public static void main(String args[]){
n=s.nextInt();
m=s.n... | Main.java:6: error: class A is public, should be declared in a file named A.java
public class A{
^
1 error
|
s007101505 | p03768 | Java | import java.util.Scanner;
import java.io.*;
import java.util.*;
import java.math.*;
import java.lang.*;
import static java.lang.Math.*;
public class Check2
{
static class InputReader
{
private InputStream stream;
private byte[] buf = new byte[1024];
private int curChar;
private int numChars;
private Spac... | Main.java:8: error: class Check2 is public, should be declared in a file named Check2.java
public class Check2
^
Note: Main.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
1 error
|
s005358744 | p03768 | C++ | #include<vector>
using namespace std;
int n, m, q;
vector<vector<int>> vertex;
vector<int> color;
void paint(int v, int d, int c) {
color[v] = c;
if (d <= 0 || vertex[v].size() <= 0)
return;
else {
for (int i = 0; i < vertex[v].size(); i++) {
paint(vertex[v][i], d-1, c);
}
}
}
int main() {
cin >> n >>... | a.cc: In function 'int main()':
a.cc:20:9: error: 'cin' was not declared in this scope
20 | cin >> n >> m;
| ^~~
a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
1 | #include<vector>
+++ |+#include <iostream>
2 | us... |
s559269997 | p03768 | C++ | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <string.h>
#include <vector>
using namespace std;
#define ll long long
#define INF (1 << 30)
#define INFLL (1LL << 60)
#define FOR(... | /tmp/cccSZ7lX.o: in function `ika(int, int, int, int)':
a.cc:(.text+0x27): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss section in /tmp/cccSZ7lX.o
/tmp/cccSZ7lX.o: in function `main':
a.cc:(.text+0x257): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .b... |
s975329939 | p03768 | C++ | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <string.h>
#include <vector>
using namespace std;
#define ll long long
#define INF (1 << 30)
#define INFLL (1LL << 60)
#define FOR(... | /tmp/ccuas3tN.o: in function `ika(int, int, int)':
a.cc:(.text+0x24): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss section in /tmp/ccuas3tN.o
/tmp/ccuas3tN.o: in function `main':
a.cc:(.text+0x259): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss se... |
s353180170 | p03768 | C++ | //部分点が狙えるかも、また、枝刈りで通ればいいなあ
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define Rep(i, N) for(int i = 0; i < N; i++)
#define pb push_back
typedef pair<int, int> Pi;
#define fi first
#define se second
vector < int > G[100005];
int color[100005] = {0};
int power[100005] = {0};
int N, M;
void ... | a.cc: In function 'void bfs(long long int, long long int, long long int)':
a.cc:28:6: error: 'd' was not declared in this scope; did you mean 'sd'?
28 | if(d == 0) return;
| ^
| sd
|
s767787340 | p03768 | C++ | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <string.h>
#include <vector>
using namespace std;
#define ll long long
#define INF (1 << 30)
#define INFLL (1LL << 60)
#define FOR(... | /tmp/cchebQLz.o: in function `main':
a.cc:(.text+0x16f): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss section in /tmp/cchebQLz.o
/tmp/cchebQLz.o: in function `ika(int, int, int)':
a.cc:(.text+0x1d3): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss s... |
s353764108 | p03768 | C++ | #include <math.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <assert.h>
#include <limits.h>
#include <stdbool.h>
void wf(int n,int d[n][n]){
int i,j,k;
for(i=0;i<n;i++){//中点
for(j=0;j<n;j++){//始点
for(k=0;k<n;k++){//終点
//printf("%d->%d->%d\n",j,i,k);
if(d[j][k]>d[j][i]+d[i][k]){
... | a.cc:9:22: error: use of parameter outside function body before ']' token
9 | void wf(int n,int d[n][n]){
| ^
a.cc:9:25: error: use of parameter outside function body before ']' token
9 | void wf(int n,int d[n][n]){
| ^
a.cc: In function 'void wf(...)':
a... |
s452091536 | p03768 | C++ | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <string.h>
#include <vector>
using namespace std;
#define ll long long
#define INF (1 << 30)
#define INFLL (1LL << 60)
#define FOR(... | /tmp/ccQZUl65.o: in function `main':
a.cc:(.text+0x16f): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss section in /tmp/ccQZUl65.o
/tmp/ccQZUl65.o: in function `ika(int, int, int)':
a.cc:(.text+0x1d3): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss s... |
s763568742 | p03768 | C++ | // acdart
#include <iostream>
#include <cstring>
#include <algorithm>
#include <cstdio>
#include <cstring>
#include <cmath>
#include <cctype>
#include <string>
#include <queue>
#include <vector>
#include <stack>
#include <set>
#include <map>
#include <bitset>
#include <cstdlib>
#include <list>
#include <limits.h>
#incl... | /tmp/ccRmaETt.o: in function `main':
a.cc:(.text+0x5a7): relocation truncated to fit: R_X86_64_PC32 against symbol `col' defined in .bss section in /tmp/ccRmaETt.o
a.cc:(.text+0x5ec): relocation truncated to fit: R_X86_64_PC32 against symbol `col' defined in .bss section in /tmp/ccRmaETt.o
collect2: error: ld returned ... |
s495893305 | p03768 | C | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <string.h>
#include <vector>
using namespace std;
#define ll long long
#define INF (1 << 30)
#define INFLL (1LL << 60)
#define FOR(... | main.c:1:10: fatal error: algorithm: No such file or directory
1 | #include <algorithm>
| ^~~~~~~~~~~
compilation terminated.
|
s467870825 | p03768 | Java | import java.util.ArrayList;
import java.util.Arrays;
import java.util.Scanner;
public class A{
static final Scanner s =new Scanner(System.in);
static int n, m, q;
static boolean checked[];
static Node nodes[];
public static void main(String args[]){
n=s.nextInt();
m=s.nextInt();
if(n>2000||m>2000... | Main.java:5: error: class A is public, should be declared in a file named A.java
public class A{
^
1 error
|
s421714874 | p03768 | C | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <string.h>
#include <vector>
using namespace std;
#define ll long long
#define INF (1 << 30)
#define INFLL (1LL << 60)
#define FOR(... | main.c:1:10: fatal error: algorithm: No such file or directory
1 | #include <algorithm>
| ^~~~~~~~~~~
compilation terminated.
|
s377636877 | p03768 | C++ | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <string.h>
#include <vector>
using namespace std;
#define ll long long
#define INF (1 << 30)
#define INFLL (1LL << 60)
#define FOR(... | /tmp/cc2eUc2J.o: in function `ika(int, int, int)':
a.cc:(.text+0x24): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss section in /tmp/cc2eUc2J.o
/tmp/cc2eUc2J.o: in function `main':
a.cc:(.text+0x259): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss se... |
s278427818 | p03768 | C++ | #include <algorithm>
#include <cstdio>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <string.h>
#include <vector>
using namespace std;
#define ll long long
#define INF (1 << 30)
#define INFLL (1LL << 60)
#define FOR(... | /tmp/ccXzUMl0.o: in function `ika(int, int, int)':
a.cc:(.text+0x24): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss section in /tmp/ccXzUMl0.o
/tmp/ccXzUMl0.o: in function `main':
a.cc:(.text+0x26a): relocation truncated to fit: R_X86_64_PC32 against symbol `color' defined in .bss se... |
s927458331 | p03768 | C++ | #include<vector>
#include<iostream>
#include<algorithm>
#include<functional>
#include<queue>
#include<set>
typedef std::vector<std::set<int>> graph_t;
void splatter(graph_t const& graph, std::vector<std::int64_t>& color,int now, int target, int dist, std::int64_t flag, int& rest)
{
if (dist == -1)
{
return;
}
i... | a.cc:10:54: error: 'int64_t' is not a member of 'std'; did you mean 'int64_t'?
10 | void splatter(graph_t const& graph, std::vector<std::int64_t>& color,int now, int target, int dist, std::int64_t flag, int& rest)
| ^~~~~~~
In file included from /usr/include... |
s748072015 | p03768 | C++ | #include<cstdio>
#include<cstdlib>
#include<cmath>
#include<iostream>
#include<string>
#include<stack>
#include<queue>
#include<vector>
#include<map>
#include<set>
#include<algorithm>
#define rep(n) for(int i=0;i<n;i++)
#define repp(j, n) for(int j=0;j<n;j++)
#define reppp(i, m, n) for(int i=m;i<=n;i++)
#define all(c)... | a.cc: In function 'void dfs(ll, ll, ll, ll, std::vector<bool>)':
a.cc:36:33: error: too few arguments to function 'void dfs(ll, ll, ll, ll, std::vector<bool>)'
36 | if(!use[to]) dfs(to, d, c, depth+1);
| ~~~^~~~~~~~~~~~~~~~~~~
a.cc:31:6: note: declared here
31 | ... |
s861953592 | p03768 | C++ | #include<iostream>
#include<cstdio>
#include<algorithm>
#include<vector>
#include<cstdlib>
#include<cmath>
#include<cstring>
using namespace std;
#define maxn 1001000
#define llg int
#define yyj(a) freopen(a".in","r",stdin),freopen(a".out","w",stdout);
llg n,m,c[maxn],Q;
vector<llg>a[maxn];
struct node
{
llg po,dis,... | a.cc: In function 'int main()':
a.cc:58:52: error: 'y' was not declared in this scope; did you mean 'yn'?
58 | for (llg i=1;i<=n;i++) printf("%d\n",c[i]);y
| ^
| yn
|
s764988534 | p03768 | C++ | #include<iostream>
#include<cstdio>
#include<vector>
#include<string>
#include<functional>
#include<algorithm>
#include<queue>
using namespace std;
int ans[100000];
vector<int>rinsetu[100000];
int mincost[100000];
signed main() {
int a, b;
cin >> a >> b;
if (a > 2000 || b > 2000)return 0;
for (int c = 0; c < b; c+... | a.cc: In function 'int main()':
a.cc:27:17: error: 'memset' was not declared in this scope
27 | memset(mincost, -1, sizeof(mincost));
| ^~~~~~
a.cc:8:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
7 | #include<queu... |
s503516963 | p03768 | C++ | #include<stdio.h>
#include<vector>
using namespace std;
#define ran 111111
int n,q;
vector<int> e[ran];
int vert[ran],query_dis[ran],query_col[ran];
int col[ran];
int dis[ran];
int que[ran],op,cl;
int inq[ran],T;
int main(){
int m;
scanf("%d%d",&n,&m);
while(m--){
int x,y;
scanf("%d%d",&x,&y);
e[x].push_back... | a.cc: In function 'int main()':
a.cc:26:9: error: 'memset' was not declared in this scope
26 | memset(dis,-1,sizeof(dis));
| ^~~~~~
a.cc:3:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
2 | #include<vector>
+++ |+#include <cstri... |
s397990021 | p03769 | C++ | #include <cstdio>
#include <vector>
int main() {
long long n;
scanf("%lld", &n);
int all = 100;
std::vector <int> p, q;
while(n > 1) {
if(n & 1) {
p.push_back(all--);
n--;
}
else {
q.push_back(all--);
n >>= 1;
}
}
int sz = p.size() + q.size();
printf("%d\n", sz + 100);
for(int x: p)
... | a.cc: In function 'int main()':
a.cc:24:14: error: 'reverse' is not a member of 'std'
24 | std::reverse(q.begin(), q.end());
| ^~~~~~~
|
s477274283 | p03769 | C++ | #include <cstdio>
#include <vector>
int main() {
long long n;
scanf("%lld", &n);
int all = 100;
std::vector <int> p, q;
while(n > 1) {
if(n & 1) {
p.push_back(all--);
n--;
}
else {
q.push_back(all--);
n >>= 1;
}
}
int sz = p.size() + q.size();
printf("%d\n", sz + 100);
for(int x: p)
... | a.cc: In function 'int main()':
a.cc:24:9: error: 'reverse' was not declared in this scope
24 | reverse(q.begin(), q.end());
| ^~~~~~~
|
s218762034 | p03769 | C++ | #include <bits/stdc++.h>
#include <random>
using namespace std;
typedef unsigned long long ull;
typedef long long ll;
typedef double ld;
//#define ll __int128
//#define int ll
//#define int ll
//#define char ll
typedef vector<char> vc;
typedef vector<vc> vvc;
typedef vector<vvc> vvvc;
typedef pair<int, int> pii;
type... | a.cc:940:7: warning: missing terminating " character
940 | a["ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^ABCDEFGHIJKLMNOPQRSTUVWXYZ[\"] = 268435455;
| ^
a.cc:940:7: error: missing terminating " character
940 | a["ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^ABCDEFGHIJKLMNOPQRSTUVWXYZ[\"] = 268435455;
| ^~~~~~~~... |
s914902019 | p03769 | C++ | #include <bits/stdc++.h>
#include <random>
using namespace std;
typedef unsigned long long ull;
typedef long long ll;
typedef double ld;
//#define ll __int128
#define int ll
//#define int ll
//#define char ll
typedef vector<char> vc;
typedef vector<vc> vvc;
typedef vector<vvc> vvvc;
typedef pair<int, int> pii;
typede... | a.cc: In function 'vl solve(ll)':
a.cc:128:30: error: expected ';' before ':' token
128 | assert(ret.size() <= 200):
| ^
a.cc:130:1: warning: control reaches end of non-void function [-Wreturn-type]
130 | }
| ^
|
s085454848 | p03769 | C++ | #include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <iostream>
#include <istream>
#include <iterator>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
#include <tuple>
#include <iomanip>
using namespace std;
typedef long long ll;
typede... | a.cc:38:17: error: 'LLONG_MAX' was not declared in this scope
38 | const ll INFL = LLONG_MAX;//10^18 = 2^60
| ^~~~~~~~~
a.cc:16:1: note: 'LLONG_MAX' is defined in header '<climits>'; this is probably fixable by adding '#include <climits>'
15 | #include <iomanip>
+++ |+#include <climits>
... |
s932172742 | p03769 | C++ | #include <bits/stdc++.h>
using namespace std;
int p[202], q[202], cnt;
long long n;
void solve(long long n){
if (!n) return;
if (~n & 1)
q[++q[0]] = cnt++, solve(n - 1);
else
p[++p[0]] = cnt++, solve(n >> 1);
}
int main(){
scanf("%lld", &n), solve(v), printf("%d\n", cnt + 100);
for (... | a.cc: In function 'int main()':
a.cc:16:34: error: 'v' was not declared in this scope
16 | scanf("%lld", &n), solve(v), printf("%d\n", cnt + 100);
| ^
|
s979415806 | p03769 | C++ | #include <cmath>
#include <iostream>
#include <vector>
#include <algorithm>
#include <string>
#include <set>
#include <map>
#include <list>
#include <time.h>
#include <math.h>
#include <random>
#include <deque>
#include <queue>
#include <cassert>
#include <unordered_map>
#include <unordered_set>
#include <iomanip>
#inc... | a.cc: In function 'int main()':
a.cc:42:3: error: 'function' was not declared in this scope
42 | function<vector<int>(ll)> solve = [&] (ll k) {
| ^~~~~~~~
a.cc:22:1: note: 'std::function' is defined in header '<functional>'; this is probably fixable by adding '#include <functional>'
21 | #include <cstri... |
s526320231 | p03769 | C++ | #include<iostream>
using namespace std;
long long N,M;
int i,j;
long long a[105];
long long b[105];
void solver(long long n){
if(n==1){
I ++;
b[I] = M--;
return ;
}
if(n&1) {
i++;
b[i]=M--;
solver(n>>=1);
}
else{
j++;
a[j]=M--;
solver(n-1);
}
}
int main()
{
long long N;
cin>>N;
M=100;
... | a.cc: In function 'void solver(long long int)':
a.cc:12:17: error: 'I' was not declared in this scope
12 | I ++;
| ^
|
s462624577 | p03769 | C++ | #include <iostream>
#include<stdio.h>
using namespace std;
int a[102];
int b[102];
int main()
{
long long n;
int p1 = 0, p2 = 0, m = 100;
scanf_s("%lld", &n);
n++;
while (n > 1)
{
if (n & 1)
{
a[++p1] = m--;
n--;
}
else
{
b[++p2] = m--;
n >>= 1;
}
}
printf("%d\n", p1 + p2 << 1);
for (in... | a.cc: In function 'int main()':
a.cc:10:9: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
10 | scanf_s("%lld", &n);
| ^~~~~~~
| scanf
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.