submission_id
stringlengths
10
10
problem_id
stringlengths
6
6
language
stringclasses
3 values
code
stringlengths
1
522k
compiler_output
stringlengths
43
10.2k
s044376348
p00700
C++
#include "bits/stdc++.h" #include<unordered_map> #include<unordered_set> #pragma warning(disable:4996) using namespace std; using ld = long double; const ld eps = 1e-9; //// < "d:\d_download\visual studio 2015\projects\programing_contest_c++\debug\a.txt" > "d:\d_download\visual studio 2015\projects\programing_contest_...
a.cc: In function 'int main()': a.cc:22:54: error: no match for 'operator==' (operand types are 'std::pair<int, int>' and 'int') 22 | if (amax < nx*nx + ny*ny||ans==nx*nx+ny*ny&&nx>ans.first) { | ~~~^~~~~~~~~~~~~ | ...
s805644750
p00700
C++
#include<iostream> using namespace std; struct P { int x,y; }; P maxP(const P a,const P b){ int la=a.x*a.x+a.y*a.y; int lb=b.x*b.x+b.y*b.y; if(la>lb)return a; if(la<lb)return b; if(a.x>b.x) return a; else return b; } int main(){ int n; cin >> n; for(int i=0;i<n;i++){ P d,p={0,0},m={0,0}; while(c...
a.cc: In function 'int main()': a.cc:32:21: error: expected ';' before 'm' 32 | cout m.x << " " << m.y << endl; | ^~ | ;
s715454806
p00701
C++
#include<iostream> #include<vector> #include<algorithm> using namespace std; int up[101]; int down[101]; bool isaonb(int a,int b){ while(up[b]){ if(a==b)return true; b=up[b]; } return false; } void overaf(int a){ while(up[a]){ int upa=up[a]; down[up[a]]=0; up[a]=0; a=upa; } down[...
a.cc:33:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] 33 | main(){ | ^~~~ a.cc: In function 'int main()': a.cc:38:5: error: 'memset' was not declared in this scope 38 | memset(up,0,sizeof(up)); | ^~~~~~ a.cc:4:1: note: 'memset' is defined in header '<cstring>';...
s373002939
p00701
C++
#include <iostream> #include <algorithm> #include <cassert> #include <cctype> #include <complex> #include <cstdio> #include <map> #include <math.h> #include <queue> #include <set> #include <stack> #include <string> #include <vector> using namespace std; #define rep(i,n) for(int i=0;i<n;i++) int m,I,J,p[10000][100],s[...
a.cc: In function 'int main()': a.cc:32:17: error: 'memset' was not declared in this scope 32 | memset(p,0,sizeof(p)); | ^~~~~~ a.cc:12:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 11 | #include <stack> +++ |+#i...
s604433974
p00701
C++
#include <iostream> #include <vector> using namespace std; typedef pair<int, int> P; bool empty(vector<int> &vi){ return vi.empty(); } int main(){ int m; while(cin >> m && m){ int I, J; vector<vector<int> > vvi; for(int i = 1; i <= m; i++){ vector<int> vi; vi.push_back(i); vvi.push_...
a.cc: In function 'int main()': a.cc:89:17: error: 'remove_if' was not declared in this scope; did you mean 'remove'? 89 | vvi.erase(remove_if(vvi.begin(), vvi.end(), empty), vvi.end()); | ^~~~~~~~~ | remove a.cc:94:5: error: 'sort' was not declared in this scope; di...
s923379326
p00703
Java
import java.util.Scanner; //FIX: Pay attention what the wild digits needs to be. //They must not be used in different ways for the same could-be-answer. //eliminate wild digit possibilities. //Nah, thats not it. //Maybe the blow counting is faulty. public class Main { static Scanner scan = new Scanner(System.in); ...
Main.java:196: error: cannot find symbol digits = new Digit[l]; ^ symbol: variable digits location: class HintSet Main.java:196: error: cannot find symbol digits = new Digit[l]; ^ symbol: class Digit location: class HintSet 2 errors
s253471123
p00703
Java
import java.util.Scanner; //FIX: Pay attention what the wild digits needs to be. //They must not be used in different ways for the same could-be-answer. //eliminate wild digit possibilities. //Nah, thats not it. //Maybe the blow counting is faulty. public class Main { static Scanner scan = new Scanner(System.in); ...
Main.java:196: error: cannot find symbol digits = new Digit[l]; ^ symbol: variable digits location: class HintSet Main.java:196: error: cannot find symbol digits = new Digit[l]; ^ symbol: class Digit location: class HintSet 2 errors
s317381743
p00703
Java
package mastermind; public class InfinityLoopTest { public static void main(String[] args) { //infinite loop test while(true) {} } }
Main.java:3: error: class InfinityLoopTest is public, should be declared in a file named InfinityLoopTest.java public class InfinityLoopTest { ^ 1 error
s147912223
p00703
C++
#include <iostream> #include <string> #include <cstdlib> #include <bitset> using namespace std; typedef long long int lli; const int MAX_H = 1000000; int L, H; lli nums[MAX_H]; int s_nums[MAX_H], hit[MAX_H], blow[MAX_H]; lli ans; void print_bit(lli n){ for(int i = 0; i < L; ++i){ cout << static_cast<bitset<4> >(n...
a.cc: In function 'std::string deco_64(lli)': a.cc:33:3: error: 'reverse' was not declared in this scope 33 | reverse(ret.begin(), ret.end()); | ^~~~~~~
s649717902
p00703
C++
#include<cstdio> #include<algorithm> #define rep(i,n) for(int i=0;i<(n);i++) using namespace std; bool isvalid(int n,const char *s,const char *tr,int hit,int blow){ rep(i,n) rep(j,n) if(s[i]==tr[j]) { if(i==j) hit--; else blow--; } return hit==0 && blow==0; } int m,idx[3628800]; char s[3628800][11]; void...
a.cc: In function 'void gen(int, int, char*, bool*)': a.cc:20:17: error: 'strcpy' was not declared in this scope 20 | strcpy(s[m],tmp); | ^~~~~~ a.cc:3:1: note: 'strcpy' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 2 | #include<al...
s093888729
p00703
C++
#include <iostream> #include <vector> #include <algorithm> #include <string> using namespace std; int L,H; string strs[1001]; int hits[1001]; int blows[1001]; int nums[1001]; bool isSelected[1001]; // nums‚Ì’†g‚Ætgt‚ð”äŠr bool check(string &tgt,int hit,int blow){ int h=0; int b=0; for(int i=0;i<tgt.size...
a.cc: In function 'int main()': a.cc:33:9: error: 'memset' was not declared in this scope 33 | memset(isSelected,0,sizeof(isSelected)); | ^~~~~~ a.cc:4:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 3 | #include <algorithm> +++ ...
s023624556
p00703
C++
#include <iostream> #include <sstream> #include <string> #include <algorithm> #include <vector> #include <stack> #include <queue> #include <set> #include <map> #include <cstdio> #include <cstdlib> #include <cstring> #include <cmath> #include <cassert> using namespace std; #define FOR(i,k,n) for(int i=(k); i<(int)n; +...
a.cc: In function 'int main()': a.cc:71:7: error: jump to label 'NEXT' 71 | NEXT: | ^~~~ a.cc:47:16: note: from here 47 | goto NEXT; | ^~~~ a.cc:50:19: note: crosses initialization of 'std::vector<int> digit' 50 | vector<int> digit; | ...
s823465961
p00704
C++
やほお
a.cc:1:1: error: '\U00003084\U0000307b\U0000304a' does not name a type 1 | やほお | ^~~~~~
s787939804
p00705
Java
import java.io.InputStream; import java.io.IOException; import java.io.PrintWriter; import java.util.ArrayList; import java.util.Arrays; import java.util.Comparator; import java.util.InputMismatchException; import java.util.NoSuchElementException; import java.math.BigDecimal; import java.math.BigInteger; public cl...
Main.java:38: error: ';' expected Arrays.fill(cnt,0) ^ 1 error
s258551011
p00705
Java
import java.io.InputStream; import java.io.IOException; import java.io.PrintWriter; import java.util.ArrayList; import java.util.Arrays; import java.util.Comparator; import java.util.InputMismatchException; import java.util.NoSuchElementException; import java.math.BigDecimal; import java.math.BigInteger; public c...
Main.java:43: error: unnamed classes are a preview feature and are disabled by default. public static void main(String[] args) throws Exception{ ^ (use --enable-preview to enable unnamed classes) Main.java:151: error: class, interface, enum, or record expected } ^ 2 errors
s864287543
p00705
Java
import java.io.InputStream; import java.io.IOException; import java.io.PrintWriter; import java.util.ArrayList; import java.util.Arrays; import java.util.Comparator; import java.util.InputMismatchException; import java.util.NoSuchElementException; import java.math.BigDecimal; import java.math.BigInteger; public c...
Main.java:43: error: unnamed classes are a preview feature and are disabled by default. public static void main(String[] args) throws Exception{ ^ (use --enable-preview to enable unnamed classes) Main.java:151: error: class, interface, enum, or record expected } ^ 2 errors
s270732809
p00705
Java
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner s = new Scanner(System.in); while (true) { int n = s.nextInt(); int q = s.nextInt(); if (n == 0 && q == 0) break; int[] day = new int[101]; for (int i = 0; i < n; i++) { int m = s.nextInt(); ...
Main.java:3: error: illegal character: '\u3000' public class?Main { ^ 1 error
s323134115
p00705
Java
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner s = new Scanner(System.in); while (true) { int n = s.nextInt(); int q = s.nextInt(); if (n == 0 && q == 0) break; int[] day = new int[101]; for (int i = 0; i < n; i++) { int m = s.nextInt(); ...
Main.java:3: error: illegal character: '\u3000' public class?Main { ^ 1 error
s256794215
p00705
C
g#include <stdio.h> #define SIZE 100 int date[SIZE + 1]; /* prototype declaration */ void init(); void count(int day); int search(int quorum); int main(int argc, const char *argv[]) { int i, j, N, Q, M, day, ans; while(1) { /* initialization */ init(); ans = 0; scanf("%d%d", &N, &Q); if(N == 0 && Q ...
main.c:1:2: error: stray '#' in program 1 | g#include <stdio.h> | ^ main.c:1:1: error: unknown type name 'g' 1 | g#include <stdio.h> | ^ main.c:1:11: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token 1 | g#include <stdio.h> | ^ main.c: In function 'main': ...
s679120453
p00705
C
#include <stdio.h> int main(){ int N, Q; int M, data; int i,j; int maxMember,maxMemberdata; while(1){ //int canAttend[100]={0,}; scanf("%d%d",&N,&Q);if(N==0&&Q==0) break; maxMember=Q-1; maxMemberdata=0; for(j=0;j<100;j++) canAttend[j]=0; for(i=0;i<N;i++){ scanf("%d", &M); for(j=0;j<M;j++){ s...
main.c: In function 'main': main.c:13:36: error: 'canAttend' undeclared (first use in this function) 13 | for(j=0;j<100;j++) canAttend[j]=0; | ^~~~~~~~~ main.c:13:36: note: each undeclared identifier is reported only once for each function it appears in
s164196172
p00705
C
#include <stdio.h> int main(){ int N, Q; int M, data; //int canAttend[100]; int i,j; int maxMember,maxMemberdata; while(true){ int canAttend[100]={0,}; scanf("%d%d",&N,&Q);if(N==0&&Q==0) break; maxMember=Q-1; maxMemberdata=0; //for(j=0;j<100;j++) canAttend[j]=0; for(i=0;i<N;i++){ scanf("%d", &M); ...
main.c: In function 'main': main.c:9:15: error: 'true' undeclared (first use in this function) 9 | while(true){ | ^~~~ main.c:2:1: note: 'true' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>' 1 | #include <stdio.h> +++ |+#include <stdbo...
s564744071
p00705
C++
#include<bits/stdc++.h> using namespace std; int main(){ int N, Q, M, temp; while(1){ int temp2[300] = {}ans = 0; cin>>N>>Q; if(N == 0 && Q == 0) break; for(int i = 1; i <= N; i++){ cin>>M; for(int j = 1; j <= M; j++){ cin>>temp; temp2[temp]++; } } for(int i = 1; i <= 250; i++...
a.cc: In function 'int main()': a.cc:8:36: error: expected ',' or ';' before 'ans' 8 | int temp2[300] = {}ans = 0; | ^~~ a.cc:22:34: error: 'ans' was not declared in this scope; did you mean 'abs'? 22 | if(temp2[ans] < temp2[i])ans ...
s659184477
p00705
C++
#include <cstdio> #include <algorithm> #include <vector> using namespace std; vector<int> l(101,0); int main(){ int i,j,N,Q,M,d; while(1){ scanf("%d %d",&N,&Q); if(!N && !Q){break;} l.fill(l.begin(),l.end(),0) for(i=0;i<N;i++){ scanf("%d",&M); for(j=...
a.cc: In function 'int main()': a.cc:13:11: error: 'class std::vector<int>' has no member named 'fill' 13 | l.fill(l.begin(),l.end(),0) | ^~~~ a.cc:14:24: error: expected ';' before ')' token 14 | for(i=0;i<N;i++){ | ^ | ;
s098124924
p00705
C++
#include <cstdio> #include <algorithm> #include <vector> using namespace std; vector<int> l(101,0); int main(){ int i,j,N,Q,M,d; while(1){ scanf("%d %d",&N,&Q); if(!N && !Q){break;} fill(l.begin(),l.end(),0) for(i=0;i<N;i++){ scanf("%d",&M); for(j=0;...
a.cc: In function 'int main()': a.cc:13:34: error: expected ';' before 'for' 13 | fill(l.begin(),l.end(),0) | ^ | ; 14 | for(i=0;i<N;i++){ | ~~~ a.cc:14:24: error: expected ';' before...
s373279298
p00705
C++
include <iostream> #include <vector> using namespace std; int main() { int N, Q; while (cin >> N >> Q, N && Q) { int avail[100] = {}; for (int i = 0; i < N; i++) { int M; cin >> M; for (int j = 0; j < M; j++) { int tmp; cin >> tmp; avail[tmp-1] += 1; } } int max = 0; int idx = -1; fo...
a.cc:1:1: error: 'include' does not name a type 1 | include <iostream> | ^~~~~~~ In file included from /usr/include/c++/14/bits/stl_algobase.h:62, from /usr/include/c++/14/vector:62, from a.cc:2: /usr/include/c++/14/ext/type_traits.h:164:35: error: 'constexpr const bool __gnu...
s499484836
p00705
C++
#include <bits/stdc++.h> #define rep(i,l,n) for(int i=l;i<n;i++) #define all(a) a.begin(),a.end() #define o(a) cout<<a<<endl using namespace std; /*int main(){ int n,q; while(1){ pair<int,int> data[101]={}; rep(i,0,101){ data[i].second=-i; } cin>>n>>q; if(n==0 && q==0) break; rep(i,0,n){ int m,d; ...
a.cc: In function 'int main()': a.cc:46:39: error: 'Max' was not declared in this scope 46 | if(it->second>Max){ | ^~~ a.cc:47:41: error: overloaded function with no contextual type information 47 | max=it->second;...
s508291869
p00705
C++
#include<iostream> using namespace std; int main(){ int N,Q,M,a; while(cin>>N>>Q){ if(N==0&&Q==0)break; int max=0; int b[51][101]={},c,d=100; for(int i=0;i<N;i++){ cin>>M; if(max<M)max=M; for(int j=0;j<M;j++){ cin>>a; b[i][j]=a; } } for(int i=0;i<N;i++) fo...
a.cc: In function 'int main()': a.cc:26:18: error: 'i' was not declared in this scope 26 | if(b[i][j]==b[l][k]){ | ^ a.cc:26:21: error: 'j' was not declared in this scope 26 | if(b[i][j]==b[l][k]){ | ^ a.cc:27:15: error: 'count1' was not dec...
s482576551
p00705
C++
#include<iostream> using namespace std; int main(){ int N,Q,M,a; while(cin>>N>>Q){ if(N==0&&Q==0)break; int max=0; int b[51][101]={},c,d=100; for(int i=0;i<N;i++){ cin>>M; if(max<M)max=M; for(int j=0;j<M;j++){ cin>>a; b[i][j]=a; } } for(int i=0;i<N;i++) fo...
a.cc: In function 'int main()': a.cc:26:18: error: 'i' was not declared in this scope 26 | if(b[i][j]==b[l][k]){ | ^ a.cc:26:21: error: 'j' was not declared in this scope 26 | if(b[i][j]==b[l][k]){ | ^ a.cc:27:15: error: 'count' was not decl...
s344009208
p00705
C++
#include <iostream> #include <string> #include <algorithm> #include <queue> #include <map> #include <set> #include <vector> #include <cmath> #include <cctype> #define rep(i,a,b) for(int i=(a);i<b;i++) #define INF 1000000000 using namespace std; bool debug=false; int main(){ int n,q; while(1){ cin>>n>>q; ...
a.cc: In function 'int main()': a.cc:46:9: error: expected primary-expression at end of input 46 | return | ^ a.cc:46:9: error: expected ';' at end of input 46 | return | ^ | ; a.cc:46:9: error: expected '}' at end of input a.cc:15:11: note: to match this '{' 15 | ...
s133131202
p00705
C++
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start': (.text+0x17): undefined reference to `main' collect2: error: ld returned 1 exit status
s115467459
p00705
C++
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start': (.text+0x17): undefined reference to `main' collect2: error: ld returned 1 exit status
s126913332
p00705
C++
#include<bits/stdc++.h> using namespace std; int main(){ int n, q,b,c,d,e; int a[1001] = { }; while(1){ cin >> n >> q; if(n==0 && q==0)break; for(int i=0;i<1001;i++){ a[i] = 0; } for(int j=0;j<n;j++){ cin >> c; for(int i=0;i<c;i++){ cin >> d; a[d]++; ...
a.cc:46:1: error: expected declaration before '}' token 46 | } | ^
s274188788
p00705
C++
#include <stdio.h> int main(){ int N, Q; int M, data; int i,j; int maxMember,maxMemberdata; while(1){ //int canAttend[100]={0,}; scanf("%d%d",&N,&Q);if(N==0&&Q==0) break; maxMember=Q-1; maxMemberdata=0; for(j=0;j<100;j++) canAttend[j]=0; for(i=0;i<N;i++){ scanf("%d", &M); for(j=0;j<M;j++){ s...
a.cc: In function 'int main()': a.cc:13:36: error: 'canAttend' was not declared in this scope 13 | for(j=0;j<100;j++) canAttend[j]=0; | ^~~~~~~~~ a.cc:18:33: error: 'canAttend' was not declared in this scope 18 | canAttend[da...
s106857540
p00706
Java
import java.io.InputStream; import java.io.IOException; import java.io.PrintWriter; import java.util.ArrayList; import java.util.Arrays; import java.util.Comparator; import java.util.InputMismatchException; import java.util.NoSuchElementException; import java.math.BigDecimal; import java.math.BigInteger; public cl...
Main.java:25: error: <identifier> expected int[][] map=new [w][h]; ^ 1 error
s490294472
p00706
C
#include <stdio.h> int main() { int n,w,h,s,t; int board[100][100]; int i,j; int x,y; int max,cnt; while(scanf("%d",&n),n){ scanf("%d%d",&w,&h); for(i = 0;i < n;i++){ scanf("%d%d",&x,&y); f[y][x] = 1; } scanf("%d%d",&s,&t); for(max = 0,y = 1; y <= h; y++){ for(x = 1;...
main.c: In function 'main': main.c:15:7: error: 'f' undeclared (first use in this function) 15 | f[y][x] = 1; | ^ main.c:15:7: note: each undeclared identifier is reported only once for each function it appears in
s374183228
p00706
C
#include <stdio.h> int main() { int n,w,h,s,t; int board[100][100]; int i,j; int x,y; int max,cnt; while(scanf("%d",&n),n){ scanf("%d%d",&w,&h); for(i = 0;i < n;i++){ scanf("%d%d",&x,&y); f[y][x] = 1; } scanf("%d%d",&s,&t); for(max = 0,y = 1; y <= h; y++){ for(x = 1;...
main.c: In function 'main': main.c:15:7: error: 'f' undeclared (first use in this function) 15 | f[y][x] = 1; | ^ main.c:15:7: note: each undeclared identifier is reported only once for each function it appears in
s819704083
p00706
C
#include<cstdio> #include<cstdlib> #include<cstring> #include<cmath> #include<cassert> #include<iostream> #include<sstream> #include<string> #include<vector> #include<queue> #include<set> #include<map> #include<utility> #include<numeric> #include<algorithm> #include<bitset> #include<complex> #include<stack> using name...
main.c:1:9: fatal error: cstdio: No such file or directory 1 | #include<cstdio> | ^~~~~~~~ compilation terminated.
s650411437
p00706
C
#include <stdio.h> #define MAX(a,b) ((a) > (b) ? (a) : (b)); int countTree(int a,int b,int c,int d,int e[][]); int main(){ int N; int i,j; while(1){ int maxNumber=0; scanf("%d",&N); if(N==0) break; scanf("%d%d",&W,&H); int map[H][W]={}; for(i=0;i<N;i++){ scanf("%d%d",&x,&y); map[x][y]=1; } scan...
main.c:4:43: error: array type has incomplete element type 'int[]' 4 | int countTree(int a,int b,int c,int d,int e[][]); | ^ main.c:4:43: note: declaration of 'e' as multidimensional array must have bounds for all dimensions except the first main.c: In function 'main'...
s684506412
p00706
C
#include <stdio.h> #define MAX(a,b) ((a) > (b) ? (a) : (b)); int countTree(int a,int b,int c,int d,int e[][]); int main(){ int N; int i,j; while(1){ int maxNumber=0; scanf("%d",&N); if(N==0) break; scanf("%d%d",&W,&H); int map[H][W]={}; for(i=0;i<N;i++){ scanf("%d%d",&x,&y); map[x][y]=1; } scan...
main.c:4:43: error: array type has incomplete element type 'int[]' 4 | int countTree(int a,int b,int c,int d,int e[][]); | ^ main.c:4:43: note: declaration of 'e' as multidimensional array must have bounds for all dimensions except the first main.c: In function 'main'...
s961241006
p00706
C
#include <stdio.h> #define MAX(a,b) ((a) > (b) ? (a) : (b)); int countTree(int a,int b,int c,int d,int e[][]); int main(){ int N; int i,j; while(1){ int maxNumber=0; scanf("%d",&N); if(N==0) break; scanf("%d%d",&W,&H); int map[H][W]={}; int x,y; for(i=0;i<N;i++){ scanf("%d%d",&x,&y); map[x][y]=1;...
main.c:4:43: error: array type has incomplete element type 'int[]' 4 | int countTree(int a,int b,int c,int d,int e[][]); | ^ main.c:4:43: note: declaration of 'e' as multidimensional array must have bounds for all dimensions except the first main.c: In function 'main'...
s873096279
p00706
C
#include <stdio.h> #define MAX(a,b) ((a) > (b) ? (a) : (b)); int countTree(int a,int b,int c,int d,int e[][]); int main(){ int N; int i,j; while(1){ int maxNumber=0; scanf("%d",&N); if(N==0) break; scanf("%d%d",&W,&H); int map[H][W]={}; int x,y; for(i=0;i<N;i++){ scanf("%d%d",&x,&y); map[x][y]=1;...
main.c:4:43: error: array type has incomplete element type 'int[]' 4 | int countTree(int a,int b,int c,int d,int e[][]); | ^ main.c:4:43: note: declaration of 'e' as multidimensional array must have bounds for all dimensions except the first main.c: In function 'main'...
s984573582
p00706
C
#include <stdio.h> #define MAX(a,b) ((a) > (b) ? (a) : (b)); int countTree(int a1,int b1,int c1,int d1,int e1[][]); int main(){ int N; int i,j; while(1){ int maxNumber=0; scanf("%d",&N); if(N==0) break; scanf("%d%d",&W,&H); int map[H][W]={}; int x,y; for(i=0;i<N;i++){ scanf("%d%d",&x,&y); map[y][...
main.c:4:47: error: array type has incomplete element type 'int[]' 4 | int countTree(int a1,int b1,int c1,int d1,int e1[][]); | ^~ main.c:4:47: note: declaration of 'e1' as multidimensional array must have bounds for all dimensions except the first main.c: In func...
s911554183
p00706
C++
#include <stdio.h> #include <string.h> #include <math.h> #include <stdlib.h> #include <limits.h> int main() { int i,j,k,l; int n; int w,h; int ww,hh; int ans,sum; int a[100][100]; while(1) { scanf("%d",&n); if(n==0){break;} else { ans=0; for(i=0;i<100;i++){for(j=0;j<100;j++){a[i][j]=0}} for...
a.cc: In function 'int main()': a.cc:24:72: error: expected ';' before '}' token 24 | for(i=0;i<100;i++){for(j=0;j<100;j++){a[i][j]=0}} | ^ | ...
s383186427
p00706
C++
#include <iostream> #include <algorithm> using namespace std; int main() { int n; while(cin >> n, n) { int w, h; cin >> w >> h; bool field[110][110]; memset(field, false, sizeof(field)); for(int i = 0; i < n; i++) { int x, y; cin >> x >> y; field[y][x] = true; } int s, t; cin ...
a.cc: In function 'int main()': a.cc:10:5: error: 'memset' was not declared in this scope 10 | memset(field, false, sizeof(field)); | ^~~~~~ a.cc:3:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 2 | #include <algorithm> +++ |+#include <...
s587451622
p00706
C++
#include <iostream> #include <algorithm> using namespace std; int main() { int n; while(cin >> n, n) { int w, h; cin >> w >> h; bool field[110][110]; memset(field, false, sizeof(field)); for(int i = 0; i < n; i++) { int x, y; cin >> x >> y; field[y][x] = true; } int s, t; cin ...
a.cc: In function 'int main()': a.cc:10:5: error: 'memset' was not declared in this scope 10 | memset(field, false, sizeof(field)); | ^~~~~~ a.cc:3:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 2 | #include <algorithm> +++ |+#include <...
s248409140
p00706
C++
#include <iostream> #include <algorithm> using namespace std; int main() { int n; while(cin >> n, n) { int w, h; cin >> w >> h; bool field[110][110]; memset(field, false, sizeof(field)); for(int i = 0; i < n; i++) { int x, y; cin >> x >> y; field[y][x] = true; } int s, t; cin ...
a.cc: In function 'int main()': a.cc:10:5: error: 'memset' was not declared in this scope 10 | memset(field, false, sizeof(field)); | ^~~~~~ a.cc:3:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 2 | #include <algorithm> +++ |+#include <...
s028172714
p00706
C++
#include<iostream> #include<algorithm> #include<string> #include<vector> using namespace std; int d[101][101]={},s,t; typedef pair<int,int> P; vector<P> V; int f(int x,int y){ int cnt=0; for(int i=0;i<t;i++){ for(int j=0;j<s;j++){ if(y+j<=w && x+i<=h){s if(d[y+j][x+i]){ cnt++; } } } } return ...
a.cc: In function 'int f(int, int)': a.cc:13:33: error: 'w' was not declared in this scope 13 | if(y+j<=w && x+i<=h){s | ^ a.cc:13:43: error: 'h' was not declared in this scope 13 | if(y+j<=w && x+i<=h){s | ...
s315761342
p00706
C++
#include "stdafx.h" #include <iostream> using namespace std; int main(void){ int N; int W, H; bool pos[101][101];//pos[x][y]; int x, y; int i, j,k,l; int S, T; int max, temp; cin >> N; while(N != 0) { cin >> W >> H; while (N--){ cin >> x >> y; pos[x][y] = true; } /* for (i = 1; i <= H; i++){...
a.cc:1:10: fatal error: stdafx.h: No such file or directory 1 | #include "stdafx.h" | ^~~~~~~~~~ compilation terminated.
s113823865
p00706
C++
#include<bits/stdc++.h> int h,w,k,l,m,a,b,s,t,u,v,i,j,x[999][999];main(){while(1){memset(x,0,1<<21);v=0;std::cin>>k;if(!k){break;}std::cin>>w>>h;for(i=0;i<k;i++){cin>>a>>b;x[a][b]=1;}cin>>s>>t;for(i=1;i<=w;i++){for(j=1;j<=h;j++){u=0;for(l=0;l<s;l++){for(m=0;m<t;m++){if(x[i+l][j+m]){u++;}}}v=v>u?v:u;}}printf("%d\n",v);}...
a.cc:2:43: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] 2 | int h,w,k,l,m,a,b,s,t,u,v,i,j,x[999][999];main(){while(1){memset(x,0,1<<21);v=0;std::cin>>k;if(!k){break;}std::cin>>w>>h;for(i=0;i<k;i++){cin>>a>>b;x[a][b]=1;}cin>>s>>t;for(i=1;i<=w;i++){for(j=1;j<=h;j++){u=0;for(l=0;l<s;l++)...
s266092575
p00706
C++
#include<bits/stdc++.h> int h,w,k,l,m,a,b,s,t,u,v,i,j,x[999][999];main(){while(1){memset(x,0,1<<21);v=0;std::cin>>k;if(!k){break;}std::cin>>w>>h;for(i=0;i<k;i++){cin>>a>>b;x[a][b]=1;}std::cin>>s>>t;for(i=1;i<=w;i++){for(j=1;j<=h;j++){u=0;for(l=0;l<s;l++){for(m=0;m<t;m++){if(x[i+l][j+m]){u++;}}}v=v>u?v:u;}}printf("%d\n"...
a.cc:2:43: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] 2 | int h,w,k,l,m,a,b,s,t,u,v,i,j,x[999][999];main(){while(1){memset(x,0,1<<21);v=0;std::cin>>k;if(!k){break;}std::cin>>w>>h;for(i=0;i<k;i++){cin>>a>>b;x[a][b]=1;}std::cin>>s>>t;for(i=1;i<=w;i++){for(j=1;j<=h;j++){u=0;for(l=0;l<s...
s715656110
p00706
C++
#include <iostream> using namespace std; int main() { int n, w, h, s, t; int f[100][100]; // field while (cin >> n, n) { cin >> w >> h; memset(f, 0, sizeof(f)); int x, y; for (int i=0; i<n; i++) { cin >> x >> y; f[y][x] = 1; } cin >> s >> t; int max = 0; for (int y...
a.cc: In function 'int main()': a.cc:12:5: error: 'memset' was not declared in this scope 12 | memset(f, 0, sizeof(f)); | ^~~~~~ a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 1 | #include <iostream> +++ |+#include <cstring> ...
s939048504
p00706
C++
#include <iostream> using namespace std; int N, W, H, X, Y, S, T, r[100][100]; int main() { while (true) { scanf("%d", &N); if (N == 0) break; memset(r, 0, sizeof(r)); scanf("%d", &W); scanf("%d", &H); for (int i = 0; i < N; i++) { scanf("%d", &X); scanf("%d", &Y); r[Y - 1][X - 1] = 1; ...
a.cc: In function 'int main()': a.cc:15:17: error: 'memset' was not declared in this scope 15 | memset(r, 0, sizeof(r)); | ^~~~~~ a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 1 | #include <iostream> +++ ...
s184899542
p00706
C++
int main(){ int n; while(1){ cin>>n; if(n==0)break; int w,h; cin>>w>>h; int d[101][101]; for(int i=0;i<101;i++)for(int j=0;j<101;j++)d[i][j]=0; for(int i=0;i<n;i++){ int x,y; cin>>x>>y; d[y][x]=1; } if(debug){ for(int i=0;i<=h;i++){ for(int j=0;j<=...
a.cc: In function 'int main()': a.cc:5:5: error: 'cin' was not declared in this scope 5 | cin>>n; | ^~~ a.cc:18:8: error: 'debug' was not declared in this scope 18 | if(debug){ | ^~~~~ a.cc:21:11: error: 'cout' was not declared in this scope 21 | cout<<d[i][j]<<" "; ...
s477498922
p00706
C++
#include<iostream> #include<iomanip> #include<math.h> #include<algorithm> #include<string> #include<vector> #include<queue> #include<stack> #include<set> #include<map> #define REP(i, N) for(ll i = 0; i < N; ++i) #define FOR(i, a, b) for(ll i = a; i < b; ++i) #define ALL(a) (a).begin(),(a).end() #define pb push_back #de...
a.cc: In lambda function: a.cc:45:56: error: expected '{' before '[' token 45 | wa[i + 1][j + 1] += [i][j + 1]; | ^ a.cc: In function 'int main()': a.cc:45:56: error: no match for 'operator[]' (operand types are 'main()::<la...
s916552263
p00706
C++
#include<iostream> #include<algorithm> #include<stack> #include<queue> #include<string> #include<set> #include<functional> using namespace std; #define INF 1<<21 #define MOD 1000000007 int main() { int N; int W, H; int a, b; int S, T; int table[105][105]; int maxx; while (1) { cin >> N; if (N == 0) { ...
a.cc: In function 'int main()': a.cc:26:9: error: 'memset' was not declared in this scope 26 | memset(table, 0, sizeof(table)); | ^~~~~~ a.cc:8:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 7 | #include<functional> +++ |+#inclu...
s469004856
p00706
C++
#include<iostream> #include<algorithm> #include<stack> #include<queue> #include<string> #include<set> #include<functional> using namespace std; #define INF 1<<21 #define MOD 1000000007 int main() { int N; int W, H; int a, b; int S, T; int table[105][105]; int maxx; while (1) { cin >> N; if (N == 0) { ...
a.cc: In function 'int main()': a.cc:26:9: error: 'memset' was not declared in this scope 26 | memset(table, 0, sizeof(table)); | ^~~~~~ a.cc:8:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 7 | #include<functional> +++ |+#inclu...
s799465201
p00706
C++
#include<iostream> #include<algorithm> #include<stack> #include<queue> #include<string> #include<set> #include<functional> using namespace std; #define INF 1<<21 #define MOD 1000000007 int main() { int N; int W, H; int a, b; int S, T; int table[105][105]; int maxx; while (1) { cin >> N; if (N == 0) { ...
a.cc: In function 'int main()': a.cc:26:9: error: 'memset' was not declared in this scope 26 | memset(table, 0, sizeof(table)); | ^~~~~~ a.cc:8:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 7 | #include<functional> +++ |+#inclu...
s395952690
p00706
C++
#include<iostream> using namespace std; bool tree[1000][1000]; int s[1000][1000]; int main(){ int n, w, h; int x, y, S, T; while(cin >> n && n){ memset(s, 0, sizeof(s)); memset(tree, false, sizeof(tree)); cin >> w >> h; for(int i = 0; i < n; i++){ cin >> x >> y; tree[x][y] = true; ...
a.cc: In function 'int main()': a.cc:11:5: error: 'memset' was not declared in this scope 11 | memset(s, 0, sizeof(s)); | ^~~~~~ a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 1 | #include<iostream> +++ |+#include <cstring> 2...
s147277293
p00706
C++
#include <memory> #include <memory.h> using namespace std; bool tree[1000][1000]; int s[1000][1000]; int main(){ int n, w, h; int x, y, S, T; while(cin >> n && n){ memset(s, 0, sizeof(s)); memset(tree, false, sizeof(tree)); cin >> w >> h; for(int i = 0; i < n; i++){ cin >> x >> y; t...
a.cc: In function 'int main()': a.cc:12:9: error: 'cin' was not declared in this scope 12 | while(cin >> n && n){ | ^~~ a.cc:4:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>' 3 | #include <memory.h> +++ |+#include <iostream> 4 ...
s433549158
p00706
C++
#include<iostream> using namespace std; int main(){ int N=0,W=0,H=0,S=0,T=0; int tree_exist[100][100]={0}; while(cin >> N,N){ cin >> W >> H; memset(tree_exist,0,sizeof(tree_exist)); int x,y; for(int i=0;i<N;i++){ cin >> x >> y; tree_exist[y][x] = 1; } cin >> S >> T; int max=0; for(int y=1;...
a.cc: In function 'int main()': a.cc:12:17: error: 'memset' was not declared in this scope 12 | memset(tree_exist,0,sizeof(tree_exist)); | ^~~~~~ a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 1 | #include<i...
s365033649
p00706
C++
#include<iostream> using namespace std; int main(){ int N=0,W=0,H=0,S=0,T=0; int tree_exist[100][100]={0}; while(cin >> N,N){ cin >> W >> H; memset(tree_exist,0,sizeof(tree_exist)); int x,y; for(int i=0;i<N;i++){ cin >> x >> y; tree_exist[y][x] = 1; } cin >> S >> T; int max=0; for(int y=1;...
a.cc: In function 'int main()': a.cc:12:17: error: 'memset' was not declared in this scope 12 | memset(tree_exist,0,sizeof(tree_exist)); | ^~~~~~ a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 1 | #include<i...
s461135173
p00706
C++
#include <iostream> using namespace std; int main() { int n, w, h, s, t; int f[100][100]; // field while (cin >> n, n) { cin >> w >> h; memset(f, 0, sizeof(f)); int x, y; for (int i=0; i<n; i++) { cin >> x >> y; f[y][x] = 1; } cin >> s >> t; int max = 0; for (int y...
a.cc: In function 'int main()': a.cc:12:5: error: 'memset' was not declared in this scope 12 | memset(f, 0, sizeof(f)); | ^~~~~~ a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 1 | #include <iostream> +++ |+#include <cstring> ...
s163080986
p00706
C++
#include<iostream> using namespace std; int main(){ int N=0,W=0,H=0,S=0,T=0; int tree_exist[100][100]={0}; while(cin >> N&&N!=0){ cin >> W >> H; memset(tree_exist,0,sizeof(tree_exist)); int x,y; for(int i=0;i<N;i++){ cin >> x >> y; tree_exist[y][x] = 1; } cin >> S >> T; int max=0; for(int ...
a.cc: In function 'int main()': a.cc:12:17: error: 'memset' was not declared in this scope 12 | memset(tree_exist,0,sizeof(tree_exist)); | ^~~~~~ a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 1 | #include<i...
s276959566
p00706
C++
#include<iostream> using namespace std; int main(){ int N=0,W=0,H=0,S=0,T=0; int tree_exist[100][100]={0}; while(1){ cin >> N; if(N==0) break; cin >> W >> H; memset(tree_exist,0,sizeof(tree_exist)); int x,y; for(int i=0;i<N;i++){ cin >> x >> y; tree_exist[y][x] = 1; } cin >> S >> T; int ...
a.cc: In function 'int main()': a.cc:14:17: error: 'memset' was not declared in this scope 14 | memset(tree_exist,0,sizeof(tree_exist)); | ^~~~~~ a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 1 | #include<i...
s564770218
p00706
C++
#include <iostream> using namespace std; #define N_MAX 1000; int main(void) { int n; int w,h; int x,y; int s,t; cin >> n; cin >> w; cin >> h; int f[N_MAX][N_MAX]; int count; int max; int i1,i2,i3,i4; /* syoki*/ for (i1=0;i1<h;i1++){ for (i2=0;i2<w;i2++){ f[i1][i2]=0; } } /* tree */ f...
a.cc: In function 'int main()': a.cc:5:19: error: expected ']' before ';' token 5 | #define N_MAX 1000; | ^ a.cc:21:15: note: in expansion of macro 'N_MAX' 21 | int f[N_MAX][N_MAX]; | ^~~~~ a.cc:21:20: error: expected primary-expression before ']' token 21 |...
s326009538
p00706
C++
cout << i << " " << j << endl;
a.cc:1:17: error: 'cout' does not name a type 1 | cout << i << " " << j << endl; | ^~~~
s654476831
p00706
C++
#include <iostream> #include <vector> #include <algorithm> #include <string> #include <cstdio> #include <map> #define rep(i, n) for(int i = 0; i < n; i++) #define FOR(i, a, b) for(int i = a; i < b; i++) #define all(v) (v).begin(), (v).end() using namespace std; typedef vector<int> vi; typedef vector<vi> vvi; typedef...
a.cc: In function 'int main()': a.cc:30:17: error: 'memset' was not declared in this scope 30 | memset(field, 0, sizeof(field)); | ^~~~~~ a.cc:7:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 6 | #include <map> +...
s362459569
p00706
C++
#include <iostream> #include <vector> using namespace std; int main(){ int N; while( cin >> N, N ){ int i, j, k, l; int W, H, S, T; cin >> W >> H; char field[100][100]; memset(field, '.', sizeof(field)); for( i = 0; i < N; i++ ){ int X, Y; cin >> X >> Y; field[X][Y] = '*'; } cin >> S >> T; ...
a.cc: In function 'int main()': a.cc:11:17: error: 'memset' was not declared in this scope 11 | memset(field, '.', sizeof(field)); | ^~~~~~ a.cc:3:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 2 | #include <vector...
s660990272
p00706
C++
#include <iostream> #include <string> using namespace std; int main(){ int N; while( cin >> N, N ){ int i, j, k, l; int W, H, S, T; cin >> W >> H; char field[100][100]; memset(field, '.', sizeof(field)); for( i = 0; i < N; i++ ){ int X, Y; cin >> X >> Y; field[X][Y] = '*'; } cin >> S >> T; ...
a.cc: In function 'int main()': a.cc:11:17: error: 'memset' was not declared in this scope 11 | memset(field, '.', sizeof(field)); | ^~~~~~ a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 1 | #include <iostre...
s913157579
p00707
Java
import java.math.BigInteger; import java.util.Arrays; import java.util.LinkedList; import java.util.Queue; import java.util.Scanner; public class Main { MyScanner sc = new MyScanner(); Scanner sc2 = new Scanner(System.in); int mod = 1000000007; int[] dx = { 1, 0 }; int[] dy = { 0, 1 }; void run() { for (;;) ...
Main.java:94: error: cannot find symbol new AOJ_1126().run(); ^ symbol: class AOJ_1126 location: class Main 1 error
s244136981
p00707
Java
public class Main { MyScanner sc = new MyScanner(); Scanner sc2 = new Scanner(System.in); int mod = 1000000007; int[] dx = { 1, 0 }; int[] dy = { 0, 1 }; void run() { for (;;) { int W = sc.nextInt(); int H = sc.nextInt(); if ((W | H) == 0) { return; } char[][] field = new char[H][W]; bo...
Main.java:3: error: cannot find symbol Scanner sc2 = new Scanner(System.in); ^ symbol: class Scanner location: class Main Main.java:3: error: cannot find symbol Scanner sc2 = new Scanner(System.in); ^ symbol: class Scanner location: class Main Main.java:19: error: cannot find symbol ...
s092101473
p00707
Java
import java.util.Scanner; import java.util.ArrayList; import java.util.List; public class AOJ_1126 { int W; int H; String[] C; int[][] table; List<String> ansList; private boolean isNum(char ch) { if(ch >= '0' && ch <= '9')return true; return false; } private boolean isStrNum(String s) { if(s.charAt(0) ...
Main.java:4: error: class AOJ_1126 is public, should be declared in a file named AOJ_1126.java public class AOJ_1126 ^ 1 error
s060793104
p00707
Java
import java.util.Scanner; public class TheSecretNumberDP { int m, n; char[][] map; Scanner in = new Scanner(System.in); String remove_zero(String s) { int k; for (k = 0; k < s.length(); k++) { if (s.charAt(k) != '0') break; } return s.substring(k, s.length()); } boolean compare(String s1, String...
Main.java:4: error: class TheSecretNumberDP is public, should be declared in a file named TheSecretNumberDP.java public class TheSecretNumberDP { ^ 1 error
s888792895
p00707
C
// Aizu 1126: The Secret Number // 2017.9.15 bal4u@uu #include <stdio.h> #include <ctype.h> #include < string.h> char d[72][72], s[72][72][72]; int a[72][72]; char ans[72]; int len; int main() { int w, h, r, c; while (scanf("%d%d", &w, &h) && w) {; memset(a, 0, sizeof(a)); for (r = 0; r < h; r++) scanf("%s", ...
main.c:6:10: fatal error: string.h: No such file or directory 6 | #include < string.h> | ^~~~~~~~~~~ compilation terminated.
s504003654
p00707
C
#define M 100 char m[M][M],s[M][M][M],r[M],*z; cmp(char *p,char *q){ int r=0; for(;*p=='0';p++); for(;*q=='0';q++); if(r=strlen(p)-strlen(q))return r; return strcmp(p,q); } main(w,h,i,j,k,l){ for(;scanf("%d%d",&w,&h),w;puts(z)){ memset(m,0xff,sizeof(m)); memset(s,0,sizeof(s)); memset(r,0,sizeof(r)); ...
main.c:3:1: error: return type defaults to 'int' [-Wimplicit-int] 3 | cmp(char *p,char *q){ | ^~~ main.c: In function 'cmp': main.c:7:8: error: implicit declaration of function 'strlen' [-Wimplicit-function-declaration] 7 | if(r=strlen(p)-strlen(q))return r; | ^~~~~~ main.c:1:1: note: inclu...
s049468622
p00707
C
#include <stdio.h> #include <string.h> #include <ctype.h> #define MAX(a,b) ((a) > (b) ? (a) : (b)); main(){ int W,H; while(1){ scanf("%d%d",&W,&H); if(W+H==0) break; int ward,m[70][70]; int maxcode; for(i=0;i<H;i++){ for(j=0;j<W;j++){ ward=getchar(); if(isdigit(ward)){ if(i+j==0) m[i][j]=wa...
main.c:6:1: error: return type defaults to 'int' [-Wimplicit-int] 6 | main(){ | ^~~~ main.c: In function 'main': main.c:13:21: error: 'i' undeclared (first use in this function) 13 | for(i=0;i<H;i++){ | ^ main.c:13:21: note: each undeclared identifier is reported o...
s830565563
p00707
C++
const int INF = 100000000; typedef double D; const double EPS = 1e-8; const double PI = 3.14159; int dx[4]={-1, 0, 1, 0}, dy[4]={0, -1, 0, 1}; using namespace std; typedef pair<int, int> P; /** Problem1126 : The Secret Number **/ const int MAX_W = 70; int W, H; char field[MAX_W][MAX_W]; string dp[MAX_W][MAX_W]; bool ...
a.cc:7:9: error: 'pair' does not name a type 7 | typedef pair<int, int> P; | ^~~~ a.cc:13:1: error: 'string' does not name a type 13 | string dp[MAX_W][MAX_W]; | ^~~~~~ a.cc:15:10: error: 'string' was not declared in this scope 15 | bool big(string s1, string s2) { | ^~~~~~ ...
s583811328
p00707
C++
#include <iostream> #include <algorithm> #include <vector> #include <stack> #include <queue> #include <map> #include <cmath> #include <string> #include <sstream> #include <iomanip> #include <complex> using namespace std; #define ll long long #define vvi vector< vector<int> > #define vi vector<int> #define All(X) X.beg...
a.cc: In function 'std::string solve(int, int, bool (*)[100])': a.cc:66:42: error: reference to 'data' is ambiguous 66 | if(sudeni[px][py]==false && '0'<=data[px][py] && data[px][py]<='9') { | ^~~~ In file included from /usr/include/c++/14/string:53, ...
s185075540
p00707
C++
#include <iostream> #include <algorithm> #include <vector> #include <stack> #include <queue> #include <map> #include <cmath> #include <string> #include <sstream> #include <iomanip> #include <complex> using namespace std; #define ll long long #define vvi vector< vector<int> > #define vi vector<int> #define All(X) X.beg...
a.cc: In function 'std::string solve(int, int, bool (*)[100])': a.cc:66:42: error: reference to 'data' is ambiguous 66 | if(sudeni[px][py]==false && '0'<=data[px][py] && data[px][py]<='9') { | ^~~~ In file included from /usr/include/c++/14/string:53, ...
s450955323
p00707
C++
#include <iostream> #include <vector> #include <cstring> #include <string> #include <algorithm> #include <iomanip> using namespace std; string b[70]; string memo[70][70]; bool comp(string& s1, string& s2) { if(s1.size() == s2.size()) return s1 < s2; return s1.size() < s2.size(); } int main() { cin.tie(0); ios::s...
a.cc: In function 'int main()': a.cc:38:92: error: cannot bind non-const lvalue reference of type 'std::string&' {aka 'std::__cxx11::basic_string<char>&'} to an rvalue of type 'std::__cxx11::basic_string<char>' 38 | if(comp(memo[i + 1][j], memo[i][j] + b[i + 1]...
s853838730
p00707
C++
#include <iostream> #include <vector> #include <cstring> #include <string> #include <algorithm> #include <iomanip> using namespace std; string b[70]; string memo[70][70]; bool comp(string& s1, string& s2) { if(s1.size() == s2.size()) return s1 < s2; return s1.size() < s2.size(); } int main() { cin.tie(0); ios::s...
a.cc: In function 'int main()': a.cc:38:92: error: cannot bind non-const lvalue reference of type 'std::string&' {aka 'std::__cxx11::basic_string<char>&'} to an rvalue of type 'std::__cxx11::basic_string<char>' 38 | if(comp(memo[i + 1][j], memo[i][j] + b[i + 1]...
s240595100
p00707
C++
#include <bits/stdc++.h> using namespace std; #define LOG(...) fprintf(stderr, __VA_ARGS__) // #define LOG(...) #define FOR(i, a, b) for(int i = (int)(a); i < (int)(b); ++i) #define REP(i, n) for(int i = 0; i < (int)(n); ++i) #define RREP(i, n) for(int i = (int)(n - 1); i >= 0; --i) #define RFOR(i, a, b) for(int i = ...
a.cc: In function 'int main()': a.cc:62:13: error: 'isnumber' was not declared in this scope 62 | if (isnumber(field[y][x]) && isnumber(field[sy][sx])) { | ^~~~~~~~
s423818967
p00707
C++
#include <bits/stdc++.h> using namespace std; #define LOG(...) fprintf(stderr, __VA_ARGS__) // #define LOG(...) #define FOR(i, a, b) for(int i = (int)(a); i < (int)(b); ++i) #define REP(i, n) for(int i = 0; i < (int)(n); ++i) #define RREP(i, n) for(int i = (int)(n - 1); i >= 0; --i) #define RFOR(i, a, b) for(int i = ...
a.cc: In function 'int main()': a.cc:62:13: error: 'isnumber' was not declared in this scope 62 | if (isnumber(field[y][x]) && isnumber(field[sy][sx])) { | ^~~~~~~~
s216591307
p00707
C++
#include <bits/stdc++.h> using namespace std; #define LOG(...) fprintf(stderr, __VA_ARGS__) // #define LOG(...) #define FOR(i, a, b) for(int i = (int)(a); i < (int)(b); ++i) #define REP(i, n) for(int i = 0; i < (int)(n); ++i) #define RREP(i, n) for(int i = (int)(n - 1); i >= 0; --i) #define RFOR(i, a, b) for(int i = ...
a.cc: In function 'int main()': a.cc:62:37: error: 'isnumber' was not declared in this scope 62 | if (isdigit(field[y][x]) && isnumber(field[sy][sx])) { | ^~~~~~~~
s105472698
p00707
C++
#include <vector> int main(){ vector<int> a(1000000000); }
a.cc: In function 'int main()': a.cc:3:1: error: 'vector' was not declared in this scope 3 | vector<int> a(1000000000); | ^~~~~~ a.cc:3:1: note: suggested alternatives: In file included from /usr/include/c++/14/vector:66, from a.cc:1: /usr/include/c++/14/bits/stl_vector.h:428:11: note: 'std...
s915335040
p00707
C++
#include<bits/stdc++.h> #define rep(i,n)for(int i=0;i<n;i++) using namespace std; typedef pair<int, int>P; char c[80][80]; struct str { string s; str(string s = "") :s(s) {} }d[80][80]; bool operator<(str a, str b) { if (a.s.size() == b.s.size())return a.s < b.s; return a.s.size() < b.s.size(); } int main() { int...
a.cc: In function 'int main()': a.cc:19:27: error: conversion from 'const char [2]' to non-scalar type 'str' requested 19 | str Max = "0"; | ^~~
s512084232
p00707
C++
#include "bits/stdc++.h" using namespace std; #define ll long long #define INF (1<<30) #define LINF (1LL<<60) //http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=1126 #define MAXH 75 #define MAXW 75 vector<vector<string>> dp(MAXH, vector<string>(MAXW)); vector<vector<int>> f(MAXH, vector<int>(MAXW)); string an...
a.cc: In function 'void dfs(int, int, std::vector<std::vector<char> >&)': a.cc:41:51: error: cannot bind non-const lvalue reference of type 'std::string&' {aka 'std::__cxx11::basic_string<char>&'} to an rvalue of type 'std::__cxx11::basic_string<char>' 41 | if (str_check(C[h][w - 1] + dp[h][w...
s523423835
p00707
C++
#include "bits/stdc++.h" using namespace std; #define ll long long #define INF (1<<30) #define LINF (1LL<<60) //http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=1126 #define MAXH 75 #define MAXW 75 vector<vector<string>> dp(MAXH, vector<string>(MAXW)); vector<vector<int>> f(MAXH, vector<int>(MAXW)); string an...
a.cc:105:6: error: redefinition of 'void dfs(int, int, std::vector<std::vector<char> >&)' 105 | void dfs(int h, int w, vector<vector<char>>& C) { | ^~~ a.cc:28:6: note: 'void dfs(int, int, std::vector<std::vector<char> >&)' previously defined here 28 | void dfs(int h, int w, vector<vector<char>>& C) { ...
s229522750
p00707
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> #include <bitset> #include <cstring> using namespace std; #define FOR(I,A,B) for(int I...
a.cc: In function 'bool calc(std::string, std::string)': a.cc:25:9: error: 'h' was not declared in this scope 25 | checked[h][w] = true; | ^ a.cc:25:12: error: 'w' was not declared in this scope 25 | checked[h][w] = true; | ^
s780289777
p00707
C++
#include <bits/stdc++.h> #define LL long long #define VI vector<int> #define VVI vector<vector<int>> #define VVVI vector<vector<vector<int>>> #define VVVVI vector<vector<vector<vector<int>>>> #define VL vector<LL> #define VVL vector<vector<LL>> #define VVVL vector<vector<vector<LL>>> #define VVVVL vector<vector<vector...
a.cc: In function 'int main()': a.cc:93:40: error: expected ')' before numeric constant 93 | ans = big(ans, dp[y][x]0; | ~ ^ | )
s616552815
p00707
C++
#include <iostream> #include <string> #include <algorithm> #define rep(i, n) for(i = 0; i < n; i++) using namespace std; int w, h; string s[70]; string dp[70][70]; bool check(int i, int j, string &prev) { if (i >= h || j >= w) return false; if (prev.length() > 0) { return '0' <= s[i][j] && s[i][j] <= '9'; } ret...
a.cc: In function 'int main()': a.cc:40:106: error: cannot bind non-const lvalue reference of type 'std::string&' {aka 'std::__cxx11::basic_string<char>&'} to an rvalue of type 'std::__cxx11::basic_string<char>' 40 | if (check(i + 1, j, dp[i][j])) dp[i + 1][j] = Max(dp[i + 1][j], dp[i...
s979095824
p00707
C++
#include <iostream> #include <string> #include <algorithm> #define rep(i, n) for(i = 0; i < n; i++) using namespace std; int w, h; string s[70]; string dp[70][70]; bool check(int i, int j, string &prev) { if (i >= h || j >= w) return false; if (prev.length() > 0) { return '0' <= s[i][j] && s[i][j] <= '9'; } ret...
a.cc: In function 'int main()': a.cc:40:106: error: cannot bind non-const lvalue reference of type 'std::string&' {aka 'std::__cxx11::basic_string<char>&'} to an rvalue of type 'std::__cxx11::basic_string<char>' 40 | if (check(i + 1, j, dp[i][j])) dp[i + 1][j] = Max(dp[i + 1][j], dp[i...
s926574856
p00707
C++
#include<iostream> #include<cstdio> #include<string> #include<vector> using namespace std; #define MAX 72 string ans; char b[MAX][MAX]; int w,h; vector<vector<string> > m; static inline string maxstr(const string &a,const string &b){ if(a.length()!=b.length()){ if(a.length()>b.length()) return a; else ret...
a.cc: In function 'int main()': a.cc:36:7: error: 'gets' was not declared in this scope; did you mean 'getw'? 36 | gets(b[i]); | ^~~~ | getw
s450446677
p00708
Java
#include<iostream> #include<cmath> using namespace std; double x[100], y[100], z[100], r[100],sum,mn,maxd=99999999.9; int n,m,mx=(1<<20),a,b,c,t,hozon; double map[100][100]; double sumcor; int p[100]; double d[100]; int visited[100]; double compute(int i, int j) { double ret; ret = sqrt((x[i]-x[j]) * (x[i]-x[j])...
Main.java:1: error: illegal character: '#' #include<iostream> ^ Main.java:2: error: illegal character: '#' #include<cmath> ^ Main.java:5: error: class, interface, enum, or record expected double x[100], y[100], z[100], r[100],sum,mn,maxd=99999999.9; ^ Main.java:6: error: class, interface, enum, or record expected int n...
s684730544
p00708
C
#include <bits/stdc++.h> using namespace std; #define rep(i, n) for(int i=0; i<(n); ++i) double cost[101][101]; double mincost[101]; bool used[101]; double x[101], y[101], z[101], r[101]; double INF = numeric_limits<double>::max(); int main(void){ int n; while(cin >> n && n) { rep(i, n) { c...
main.c:1:10: fatal error: bits/stdc++.h: No such file or directory 1 | #include <bits/stdc++.h> | ^~~~~~~~~~~~~~~ compilation terminated.
s347015954
p00708
C
#include <bits/stdc++.h> #define REP(i,n) for(int i=0; i<(int)(n); ++i) #define FOR(i,k,n) for(int i=(k);i<(int)(n);++i) typedef long long int ll; using namespace std; struct UnionFind { vector<int> par; vector<int> rank; UnionFind(int n) : par(n), rank(n, 1) { for(int i=0; i<n; ++i) par[i] = i; } in...
main.c:1:10: fatal error: bits/stdc++.h: No such file or directory 1 | #include <bits/stdc++.h> | ^~~~~~~~~~~~~~~ compilation terminated.
s369880505
p00708
C
/********************** *@Name: * *@Author: Nervending *@Describtion: *@DateTime: 2017-10-16 19:48:25 ***********************/ #include <iostream> #include <string.h> #include <algorithm> #include <math.h> using namespace std; const int maxn=1e2+10; const int maxm=1e4+1000; int root[maxn]; struct node { int from,to; ...
main.c:8:10: fatal error: iostream: No such file or directory 8 | #include <iostream> | ^~~~~~~~~~ compilation terminated.
s050126103
p00708
C
//kruskal tree #include <iostream> #include <vector> #include <algorithm> #include <cmath> using namespace std; #define M 9999 int parent[M],a[M],b[M]; pair<double,int>node[M]; int root(int a){return parent[a]==a?a:parent[a]=root(parent[a]);} int unite(int a,int b){ int x=root(a),y=root(b); if(x==y)return 0; parent[...
main.c:2:10: fatal error: iostream: No such file or directory 2 | #include <iostream> | ^~~~~~~~~~ compilation terminated.
s480093454
p00708
C
#include <math.h> #include <stdio.h> #include <stdlib.h> typedef struct { double x, y, z, r; } Coord; typedef struct { int from, to; double weight; } Edge; Coord coord[ 100 ]; int parent[ 100 ]; Edge edge[ 4950 ]; int compare( const void *a, const void *b ) { double at = (*(Edge *)a).weight, bt = (*(Edge *)b).we...
main.c:33:11: error: expected '{' before '(' token 33 | void union( int x, int y ) { | ^ main.c:33:6: error: two or more data types in declaration specifiers 33 | void union( int x, int y ) { | ^~~~~ main.c: In function 'kruskal': main.c:49:30: error: expected '{' before '(' token 49...
s983224595
p00708
C++
3 10.000 10.000 50.000 10.000 40.000 10.000 50.000 10.000 40.000 40.000 50.000 10.000 2 30.000 30.000 30.000 20.000 40.000 40.000 40.000 20.000 5 5.729 15.143 3.996 25.837 6.013 14.372 4.818 10.671 80.115 63.292 84.477 15.120 64.095 80.924 70.029 14.881 39.472 85.116 71.369 5.553 0
a.cc:1:1: error: expected unqualified-id before numeric constant 1 | 3 | ^