submission_id
stringlengths
10
10
problem_id
stringlengths
6
6
language
stringclasses
3 values
code
stringlengths
1
522k
compiler_output
stringlengths
43
10.2k
s010008286
p00297
C++
#include<bits/std++.h> using namespace std; /** vector<int>ar(3); for(auto&e:ar){ scanf("%d",&e); } sort(ar.begin(),ar.end()) int sum=accumulate(ar.begin(),ar.end(),0); **/ //memo kyuridenamida 1237852 int main(){ double pai=3.141592653589; int N,d; cin >> N >> d; vector< array<int,3> > star...
a.cc:1:9: fatal error: bits/std++.h: No such file or directory 1 | #include<bits/std++.h> | ^~~~~~~~~~~~~~ compilation terminated.
s849191583
p00297
C++
#include <iostream> #include <limits.h> #include <algorithm> #include <string> #include <math.h> #include <vector> #include <cstdio> using namespace std; #define MAX_N 200000 #define F first #define Se second #define MP(i, j) make_pair((i), (j)) #define int long long struct S{ int sx, lx, sy, ly; S(int isx, int ilx, ...
a.cc:47:41: error: 'N' was not declared in this scope 47 | int i, j, n, d, stars[MAX_N][3], ax[2 * N], bx[2 * N], ay[2 * N], by[2 * N]; | ^ a.cc:47:52: error: 'N' was not declared in this scope 47 | int i, j, n, d, stars[MAX_N][3], ax[2 * N], bx[2 * N], ay[2 * N], by[...
s036492530
p00297
C++
#include <iostream> #include <limits.h> #include <algorithm> #include <string> #include <math.h> #include <vector> #include <cstdio> using namespace std; #define N 200000 #define F first #define Se second #define MP(i, j) make_pair((i), (j)) #define int long long struct S{ int sx, lx, sy, ly; S(int isx, int ilx, int ...
a.cc:47:23: error: 'MAX_N' was not declared in this scope 47 | int i, j, n, d, stars[MAX_N][3], ax[2 * N], bx[2 * N], ay[2 * N], by[2 * N]; | ^~~~~
s020229748
p00297
C++
typedef int unsigned long long; #include <cstdio> #include <vector> #include <map> #include <cmath> #include <algorithm> using namespace std; struct stars { int maxx=0,minx=0; int maxy=0,miny=0; }; signed main() { map<int, stars> data; int n, d; scanf("%llu %llu", &n, &d); stars foo; int x, y, b; for (i...
a.cc:2:28: error: declaration does not declare anything [-fpermissive] 2 | typedef int unsigned long long; | ^~~~
s289034240
p00297
C++
#include<iostream> #include<iomanip> #include<cstdlib> #include<stdio.h> #include<time.h> #include<math.h> #include<algorithm> #include<string> #include<vector> #include<list> #include<queue> #include<stack> #include<deque> #include<set> #include<map> #define REP(i, N) for(ll i = 0; i < N; ++i) #define FOR(i, a, b) for...
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/c++allocator.h:33, from /usr/include/c++/14/bits/allocator.h:46, from /usr/include/c++/14/string:43, from /usr/include/c++/14/bits/locale_classes.h:40, from /usr/include/c++/14/bits/ios_ba...
s839644278
p00297
C++
#include<bits/stdc++.h> #define int long long int #define rep(a,b,c) for(int a=b;a<c;a++) #define repm(a,b,c) for(int a=(b-1);a>=c;a--) #define pb push_back #define str string #define sf(a) scanfs("%d",&a) #define pb push_back #define mp make_pair #define Fi first #define Se second #define ALL(v) (v).begin(), (v).end(...
a.cc:63:14: error: 'SegMin y1' redeclared as different kind of entity 63 | SegMin x1,x2,y1,y2; | ^~ In file included from /usr/include/features.h:523, from /usr/include/x86_64-linux-gnu/c++/14/bits/os_defines.h:39, from /usr/include/x86_64-linux-gnu/c++/14/bits/c+...
s540599643
p00297
C++
#include<bits/stdc++.h> #define int long long int #define rep(a,b,c) for(int a=b;a<c;a++) #define repm(a,b,c) for(int a=(b-1);a>=c;a--) #define pb push_back #define str string #define sf(a) scanfs("%d",&a) #define pb push_back #define mp make_pair #define Fi first #define Se second #define ALL(v) (v).begin(), (v).end(...
a.cc:63:14: error: 'SegMin y1' redeclared as different kind of entity 63 | SegMin x1,x2,y1,y2; | ^~ In file included from /usr/include/features.h:523, from /usr/include/x86_64-linux-gnu/c++/14/bits/os_defines.h:39, from /usr/include/x86_64-linux-gnu/c++/14/bits/c+...
s320564553
p00297
C++
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int, int> P; #define pb push_back #define in , #define rep(i, a, n) for(int i = (a); i < (n); i++) #define dep(i, a, n) for(int i = (a); i >= (n); i--) #define mod 1e9+7 __attribute__((constructor)) void initial() { cin.tie(0); ios:...
a.cc:51:1: error: '::main' must return 'int' 51 | ll main() { | ^~
s139553989
p00298
C++
#pragma GCC optimize("Ofast") #include <stdio.h> #include <utility> using namespace std; int min(int a,int b){return a>b?b:a;} struct man{ int wei; int pow; void in(){ scanf("%d%d",&pow,&wei); return ; } void carry(man a){ wei+=a.wei; pow-=a.wei; pow=min(pow,...
a.cc: In member function 'void man::carry(man)': a.cc:18:16: error: return-statement with a value, in function returning 'void' [-fpermissive] 18 | return *this; | ^~~~~
s069169771
p00298
C++
#include <iostream> #include <algorithm> #include <string> #include <math.h> #include <vector> #include <cstdio> using namespace std; #define N 1000 #define F first #define S second typedef pair<int, int> P; int main(){ int n, c[N], w[N]; P dp[N][2] = {}; cin >> n; for(int i = 0; i < n; i++){ cin >> c[i] >> w[i];...
a.cc: In function 'int main()': a.cc:19:24: error: no match for 'operator=' (operand types are 'P' {aka 'std::pair<int, int>'} and 'int') 19 | dp[0][0] = -w[0]; | ^ In file included from /usr/include/c++/14/bits/stl_algobase.h:64, from /usr/include/c++/14/string:...
s029926689
p00298
C++
using namespace std; int n, w[1000], c[1000], r[1000], dp[1000][1000]; int main() { cin >> n; for (int i = 1; i <= n; i++) { cin >> c[i] >> w[i]; r[i] = w[i]; } for (int i = 1; i <= n; i++)r[i] += r[i - 1]; for (int i = 1; i <= n; i++) { dp[i][i] = 1; } for (int i = 0; i < n; i++) { for (int j =...
a.cc: In function 'int main()': a.cc:4:5: error: 'cin' was not declared in this scope 4 | cin >> n; for (int i = 1; i <= n; i++) { cin >> c[i] >> w[i]; r[i] = w[i]; } | ^~~ a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>' +++ |+#i...
s212031398
p00299
C++
// AOJ 0304 #include<iostream> #include<string> #include<vector> #define rep(i,a) for(int i=0;i<(a);++i) typedef std::pair<int, int> P; const int MAX_N = 100, MAX_C = 200, INF = std::numeric_limits<int>::max()>>2; struct edge { int from, to, cost; edge( int from, int to, int cost ) : from(from), to(to), cost(cos...
a.cc:9:48: error: 'numeric_limits' is not a member of 'std' 9 | const int MAX_N = 100, MAX_C = 200, INF = std::numeric_limits<int>::max()>>2; | ^~~~~~~~~~~~~~ a.cc:9:63: error: expected primary-expression before 'int' 9 | const int MAX_N = 100, MAX_C = 200, I...
s659217612
p00300
Java
import java.util.Scanner; //0305 public class a { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); while (n-- > 0) { int r = sc.nextInt(); int t = sc.nextInt(); String a = ""; for (int y = 0; ...
Main.java:4: error: class a is public, should be declared in a file named a.java public class a { ^ 1 error
s065706946
p00300
Java
import java.util.Scanner; public class a{ public static void main(String[]args){ Scanner sc = new Scanner(System.in); int n=sc.nextInt(); while(n-->0){ int r=sc.nextInt(),t=sc.nextInt();String a=""; for(int y=0;y<(t%30>0?2:1);y++) for(int x=0;x<(r%100>0?2:1);x++,a+=(t/30+y)*5+r/100+x) if((x|y)==1) a+=""; System.out.pr...
Main.java:3: error: class a is public, should be declared in a file named a.java public class a{ ^ 1 error
s643441491
p00300
C++
#include <stdio.h> int main(){ int n; scanf("%d",&n); while(n--){ scanf("%d%d",&r,&t); if(r%100==0){ if(t%60==0)printf("%d\n",(t/60)*5+r/100); else printf("%d %d\n",(t/60)*5 +r/100,(t/60+1)*5 +r/100); } else{ if(t%60==0)printf("%d %d\n",(t/...
a.cc: In function 'int main()': a.cc:6:23: error: 'r' was not declared in this scope 6 | scanf("%d%d",&r,&t); | ^ a.cc:6:26: error: 't' was not declared in this scope 6 | scanf("%d%d",&r,&t); | ^
s207739168
p00300
C++
#include <set> using namespace std; int main(){ int n,x0,y0,x1,y1; for(scanf("%d",&n);n--;){ scanf("%d%d",&x0,&y0); x1=(x0+99)/100; y1=(y0+29)/30; x0/=100; y0/=30; set<int>se; se.insert(y0*5+x0); se.insert(y0*5+x1); se.insert(y1*5+x0); se.insert(y1*5+x1); bool first=true; for(set<int>::iterato...
a.cc: In function 'int main()': a.cc:5:13: error: 'scanf' was not declared in this scope 5 | for(scanf("%d",&n);n--;){ | ^~~~~ a.cc:18:35: error: 'putchar' was not declared in this scope; did you mean 'char'? 18 | if(!first)putchar(' '); | ...
s258758193
p00300
C++
#include<iostream> #include<vector> using namespace std; int main(){ int n; int r; int t; vector<int> target; vector<int> k; vector<vector<int>> result; cin >> n; for(int i=0;i<n;++i){ cin>>r>>t; if(r==100) target.push_back(1); else if(r>100 && r<200){ target.pus...
a.cc: In function 'int main()': a.cc:66:7: error: expected '}' before 'else' 66 | else if(t>60 && t<90){ | ^~~~ a.cc:61:28: note: to match this '{' 61 | else if(t>30 && t<60){ | ^
s813542312
p00300
C++
c
a.cc:1:1: error: 'c' does not name a type 1 | c | ^
s578608653
p00300
C++
include<iostream> using namespace std; int main(){ int n; cin>>n; int r[51],t[51]; for(int i=0;i<n;i++){ int bufa=0; cin>>r[i]>>t[i]; if(r[i]%100==0){ if(t[i]%30==0||t[i]==0){ cout<<(r[i]/100)+5*(t[i]/30)<<endl;//頂点上 } ...
a.cc:1:1: error: 'include' does not name a type 1 | include<iostream> | ^~~~~~~ a.cc: In function 'int main()': a.cc:7:9: error: 'cin' was not declared in this scope 7 | cin>>n; | ^~~ a.cc:15:15: error: 'cout' was not declared in this scope 15 | cout<<(r[i]/100)+5*(t...
s314883322
p00300
C++
include<iostream> using namespace std; int main(){ int n; cin>>n; int r[51],t[51]; for(int i=0;i<n;i++){ int bufa=0; cin>>r[i]>>t[i]; if(r[i]%100==0){ if(t[i]%30==0||t[i]==0){ cout<<(r[i]/100)+5*(t[i]/30)<<endl;//頂点上 } ...
a.cc:1:1: error: 'include' does not name a type 1 | include<iostream> | ^~~~~~~ a.cc: In function 'int main()': a.cc:7:9: error: 'cin' was not declared in this scope 7 | cin>>n; | ^~~ a.cc:15:15: error: 'cout' was not declared in this scope 15 | cout<<(r[i]/100)+5*(t...
s914651504
p00300
C++
#include<iostream> using namespace std; int main(){ int n; cin>>n; int r[51],t[51]; for(int i=0;i<n;i++){ int bufa=0; cin>>r[i]>>t[i]; if(r[i]%100==0){ if(t[i]%30==0||t[i]==0){ cout<<(r[i]/100)+5*(t[i]/30)<<endl;//頂点上 }...
a.cc: In function 'int main()': a.cc:30:2: error: expected '}' at end of input 30 | } | ^ a.cc:4:11: note: to match this '{' 4 | int main(){ | ^
s919899273
p00300
C++
#include<bits/stdc++.h> using namespace std; int main(){ int n, r, t, ten[10]; cin>>n; for(int i = 0; i < n; i++){ cin>>r>>t; if(r%100 == 0){//cout<<"A"<<endl; if(t%30 == 0){//cout<<"B"<<endl; ten[0] = r/100 + (t/30)*5; t =1; } else { ten[0] = r/100 + (t/30)*5; ten[1] = r/100 + (t/30)...
a.cc: In function 'int main()': a.cc:21:19: error: expected ')' before '{' token 21 | if(t%30 == 0{ | ~ ^ | ) a.cc:32:5: error: expected primary-expression before '}' token 32 | } | ^
s110899031
p00301
C
#include <stdio.h> #include <string.h> char result[12]; int num; char p: int main() { int rem,flag; scanf("%d",&num); memset(result,0,sizeof(result)); p=result[10]; while(num) { flag=0; rem = num % 3; if(num==1) p[0]++; else if(num==2) { p[0]--; p[-1]++; flag = 1; } ...
main.c:6:7: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token 6 | char p: | ^
s892339985
p00301
C++
#include <string> #include <iostream> #pragma warning(disable : 4996) using namespace std; const int power[12] = { 1, 3, 9, 27, 91, 243, 729, 2187, 6561, 19683, 59049, 177141 }; int n; void solve(int x, int v, string S) { if (x == 12) return; if (v == n) { reverse(S.begin(), S.end()); printf("%s\n", S.c_str()); retur...
a.cc: In function 'void solve(int, int, std::string)': a.cc:9:23: error: 'reverse' was not declared in this scope 9 | if (v == n) { reverse(S.begin(), S.end()); printf("%s\n", S.c_str()); return; } | ^~~~~~~
s451828086
p00301
C++
#pragma once #include <stdio.h> #include <string> #include <iostream> using namespace std; double z; long w; long zmax=0; long start; int result[100]={}; bool find =false; string S; //3/11; int main(){ scanf("%ld",&w); z=(double)w; while(z>=3){ z/=3; zmax++; } S+="+"; switch(zmax){ case 0: f...
a.cc:1:9: warning: #pragma once in main file 1 | #pragma once | ^~~~ a.cc: In function 'int main()': a.cc:31:113: error: reference to 'find' is ambiguous 31 | find =true; | ...
s470604980
p00301
C++
#pragma once #include <stdio.h> #include <string> #include <iostream> using namespace std; double z; long w; long zmax=0; long start; int result[100]={}; bool find =false; string S; int main(){ scanf("%ld",&w); z=(double)w; while(z>=3){ z/=3; zmax++; } S+="+"; switch(zmax){ case 0: for(int m...
a.cc:1:9: warning: #pragma once in main file 1 | #pragma once | ^~~~ a.cc: In function 'int main()': a.cc:30:113: error: reference to 'find' is ambiguous 30 | find =true; | ...
s599150143
p00301
C++
import java.util.Scanner; // 0306 class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n=sc.nextInt(),a[]=new int[15],i=0; while(n>0) { a[i++]=(n+1)%3-1; n=(n-a[i-1])/3; } while(i-->0) System.out.pr...
a.cc:1:1: error: 'import' does not name a type 1 | import java.util.Scanner; | ^~~~~~ a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts' a.cc:4:11: error: expected ':' before 'static' 4 | public static void main(String[] args) { | ^~~~~~~ | : a.cc:4:29: e...
s912338795
p00303
C++
#include<bits/stdc++.h> using namespace std; #define int long long typedef pair<int,int>pint; typedef vector<int>vint; typedef vector<pint>vpint; #define pb push_back #define mp make_pair #define fi first #define se second #define all(v) (v).begin(),(v).end() #define rep(i,n) for(int i=0;i<(n);i++) #define reps(i,f,n)...
a.cc:55:2: error: unterminated argument list invoking macro "rep" 55 | } | ^ a.cc: In function 'bool dfs(long long int, long long int, long long int)': a.cc:29:5: error: 'rep' was not declared in this scope 29 | rep(i,G[v].size(){ | ^~~ a.cc:29:8: error: expected '}' at end of input 29 | ...
s854177722
p00303
C++
#include <iostream> #include <algorithm> #include <vector> #include <cstdio> #include <string> #include <set> #include <map> #include <queue> #include <stack> #include <cmath> #include <functional> #include <numeric> #include <iomanip> #define fi first #define se second #define fcout(n) cout<<fixed<<setprecision((n)) #...
a.cc: In function 'int scc()': a.cc:58:9: error: 'memset' was not declared in this scope 58 | memset(used, 0, sizeof(used)); | ^~~~~~ a.cc:14:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 13 | #include <iomanip> +++ |+#include <...
s923515685
p00303
C++
#include <iostream> #include <algorithm> #include <vector> #include <cstdio> #include <string> #include <set> #include <map> #include <queue> #include <stack> #include <cmath> #include <functional> #include <numeric> #include <iomanip> #define fi first #define se second #define fcout(n) cout<<fixed<<setprecision((n)) #...
a.cc: In function 'int scc()': a.cc:58:9: error: 'memset' was not declared in this scope 58 | memset(used, 0, sizeof(used)); | ^~~~~~ a.cc:14:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 13 | #include <iomanip> +++ |+#include <...
s250114559
p00303
C++
#include <iostream> #include <algorithm> #include <vector> #include <cstdio> #include <string> #include <set> #include <map> #include <queue> #include <stack> #include <cmath> #include <functional> #include <numeric> #include <iomanip> #define fi first #define se second #define fcout(n) cout<<fixed<<setprecision((n)) #...
a.cc: In function 'int scc()': a.cc:58:9: error: 'memset' was not declared in this scope 58 | memset(used, 0, sizeof(used)); | ^~~~~~ a.cc:14:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>' 13 | #include <iomanip> +++ |+#include <...
s293844730
p00303
C++
#include "iostream" #include "queue" using namespace std; int Q; int U, D; char query[5]; queue<int> dir[201]; int Now, Next; bool Is_use[201]; int main() { cin >> Q; for (int i = 0; i < Q; i++) { cin >> U >> query >> D; if (query[0] == 'w') { dir[U].push(D + 100); } else { dir[D + 100].push(U); } ...
a.cc: In function 'int main()': a.cc:45:18: error: expected '}' at end of input 45 | return 0; | ^ a.cc:12:12: note: to match this '{' 12 | int main() { | ^
s569865273
p00303
C++
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int, int> P; #define pb push_back #define rep(i, a, n) for(int i = (a); i < (n); i++) #define dep(i, a, n) for(int i = (a); i >= (n); i--) #define mod 1e9+7 __attribute__((constructor)) void initial() { cin.tie(0); ios::sync_with_st...
a.cc:21:27: error: expected initializer before ':' token 21 | int doneU[101], doneD[101]: | ^ a.cc: In function 'void solve(int, int, std::map<int, int>, std::map<int, int>)': a.cc:25:6: error: 'f' was not declared in this scope 25 | if(f) return; | ^ a.cc:28:7: error:...
s574427810
p00304
C++
#include <bits/stdc++.h> using namespace std; #define int long long int nonempty[1000]; int empty[1000]; vector<int> g[1000]; string type[1000]; int MOD = 1e9 + 7; void dfs(int x){ // preprocess for(int j = 0 ; j < g[x].size() ; j++){ dfs(g[x][j]); } if( type[x][0] != 'E' ){ // main process empty[x] = ty...
a.cc: In function 'void dfs(long long int)': a.cc:17:17: error: reference to 'empty' is ambiguous 17 | empty[x] = type[x].back() == '?'; | ^~~~~ In file included from /usr/include/c++/14/string:53, from /usr/include/c++/14/bitset:52, from /usr/i...
s754609626
p00304
C++
#include<cstdio> #include<iostream> #include<string> #include<algorithm> #include<cmath> #include<cstring> #include<vector> #include<cstdlib> using namespace std; #define rep(i,n) for(int i=0;i<n;i++) #define rep1(i,n) for(int i=1;i<=n;i++) #define rrep(i,n) for(int i=n-1;i>=0;i--) #define rrep1(i,n) for(int i=n;i>=1;...
a.cc: In function 'int dfs(int)': a.cc:48:44: error: expected ';' before 'res' 48 | res+= dfs(ch[v][i]) | ^ | ; 49 | res%=mod; | ~~~ ...
s220748150
p00304
C++
#include<cstdio> #include<iostream> #include<string> #include<algorithm> #include<cmath> #include<cstring> #include<vector> #include<cstdlib> using namespace std; #define rep(i,n) for(int i=0;i<n;i++) #define rep1(i,n) for(int i=1;i<=n;i++) #define rrep(i,n) for(int i=n-1;i>=0;i--) #define rrep1(i,n) for(int i=n;i>=1;...
a.cc: In function 'int dfs(int)': a.cc:53:9: error: 'else' without a previous 'if' 53 | else if(d[v].type==2){ | ^~~~
s098546123
p00305
Java
public class Main { public static void main (String[] args) { Scanner scan = new Scanner(System.in); int N = 300; int n = scan.nextInt(); int[][] p = new int[N+1][N+1]; int[][] sp = new int[N+1][N+1]; for (int i = 1; i <= n; i++) { for (int j = 1; j <= n; j++) { p[i][j] = scan.nextInt(); } } ...
Main.java:3: error: cannot find symbol Scanner scan = new Scanner(System.in); ^ symbol: class Scanner location: class Main Main.java:3: error: cannot find symbol Scanner scan = new Scanner(System.in); ^ symbol: class Scanner location: class Main 2 errors
s613439952
p00305
Java
public class Main { public static void main (String[] args) { Scanner scan = new Scanner(System.in); int N = 300; int n = scan.nextInt(); int[][] p = new int[N+1][N+1]; int[][] sp = new int[N+1][N+1]; for (int i = 1; i <= n; i++) { for (int j = 1; j <= n; j++) { p[i][j] = scan.nextInt(); } } ...
Main.java:3: error: cannot find symbol Scanner scan = new Scanner(System.in); ^ symbol: class Scanner location: class Main Main.java:3: error: cannot find symbol Scanner scan = new Scanner(System.in); ^ symbol: class Scanner location: class Main 2 errors
s511972656
p00305
Java
import java.util.Scanner; public class Main { static int[][] t; static int[][] u; static int n; public static void main (String[] args) { int N =300; t = new int[N+1][N+1]; u = new int[N+1][N+1]; Scanner scan = new Scanner(System.in); n =scan.nextInt(); for(int i=1;i<=n;i++){ for(int j=1;j<=n;j++){ ...
Main.java:49: error: reached end of file while parsing return res; ^ 1 error
s054764517
p00305
C++
#include <algorithm> #include <iostream> #include <queue> #define N 300 using namespace std; typedef pair<int,int> P; int n,p[N][N],s,ans,a1,a2,b1,b2,d[N][N]; priority_queue<P> A,B; int main(){ cin>>n; for(int i=0;i<n;i++) for(int j=0;j<n;j++) cin>>p[i][j]; for(int i=0;i<n;i++){ s=0; for(int j=0;j<n;...
a.cc: In function 'int main()': a.cc:51:12: error: 'else' without a previous 'if' 51 | }else ans=max(ans,sum); | ^~~~ a.cc:51:29: error: 'sum' was not declared in this scope 51 | }else ans=max(ans,sum); | ^~~ a.cc: At global scope: a.cc:56:3: ...
s929723392
p00305
C++
#include <algorithm> #include <iostream> #define N 310 #define INF (1e9) #define make make_pair using namespace std; typedef pair<int,int> P; int n,p[N][N],ans,d[N][N]; P c[N][N]; int main(){ cin>>n; for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) cin>>p[i][j]; for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) d[i...
a.cc: In function 'int main()': a.cc:28:19: error: 'j' was not declared in this scope 28 | int sum=d[j][l]-d[i-1][l]-d[j][k-1]+d[i-1][k-1],sum2=0; | ^ a.cc:29:28: error: 'sum2' was not declared in this scope; did you mean 'sum'? 29 | if(j-i>=2&&l-k>=2) sum2=d[j-1][l-1]-d[i]...
s200133251
p00305
C++
#include <algorithm> #include <iostream> #define N 310 #define INF (1e9) #define make make_pair using namespace std; typedef pair<int,int> P; int n,p[N][N],ans,d[N][N]; P c[N][N]; int main(){ cin>>n; for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) cin>>p[i][j]; for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) d[i...
a.cc: In function 'int main()': a.cc:27:23: error: cannot convert 'P' {aka 'std::pair<int, int>'} to 'int' in initialization 27 | for(int i=c[k][l];i<=n;i++){ | ~~~~~~^ | | | P {aka std::pair<int, int>} a.cc:28:19: error: 'j' was not...
s727673927
p00305
C++
#include <algorithm> #include <iostream> #define N 310 #define INF (1e9) using namespace std; int n,p[N][N],ans,c,ma,d[N][N]; int main(){ cin>>n; for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) cin>>p[i][j]; for(int i=1;i<=n;i++) for(int j=1;j<=n;j++) d[i][j]=p[i][j]; for(int i=1;i<=n;i++) for(int j=2;...
a.cc: In function 'int main()': a.cc:20:28: error: invalid types 'int[int]' for array subscript 20 | for(int j=1;j<=n;j++) c[i][j]=P(1,-INF); | ^ a.cc:20:35: error: 'P' was not declared in this scope 20 | for(int j=1;j<=n;j++) c[i][j]=P(1,-INF); | ...
s014286626
p00305
C++
#include <bits/stdc++.h> using namespace std; #define REP(i, n) FOR(i, 0, n) #define FOR(i, a, b) for(int i = a; i < b; i++) #define PB push_back #define MOD 1000000007LL typedef long long ll; int a[321][321]; int sm[321][321]; int cnt(int a, int b, int c, int d){ return sm[c][d]-sm[a][d]-sm[c][b]+sm[a][b]; } in...
a.cc:19:8: error: ISO C++ forbids declaration of 'gt' with no type [-fpermissive] 19 | inline gt(int i, int j, int k, int l){ | ^~
s344096520
p00309
C++
#include <stdio.h> #include <set> #include <queue> using namespace std; const int MOD=1e9+7; const int N=1e2+10; int p[N]; int find(int n){ return p[n]==n?n:p[n]=find(p[n]); } struct side{ int from; int to; int length; void in(){ scanf("%d%d%d",&from,&to,&length); return ; } ...
a.cc: In function 'void dfs(int)': a.cc:86:13: error: reference to 'size' is ambiguous 86 | ns+=size[now]; | ^~~~ In file included from /usr/include/c++/14/set:65, from a.cc:2: /usr/include/c++/14/bits/range_access.h:272:5: note: candidates are: 'template<class _Tp, long un...
s809474662
p00310
Java
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; import static java.lang.Integer.parseInt; /** * The Number of Participants */ public class P0315 { public static void main(String[] args) throws IOException { BufferedReader br = new Bu...
Main.java:11: error: class P0315 is public, should be declared in a file named P0315.java public class P0315 { ^ 1 error
s698906690
p00310
C
#include<stdio.h> int main(void){ int p,m,c; scanf("%d %d %d",&p,&m,&c); printf("%d\n",a+m+c); return 0; }
main.c: In function 'main': main.c:9:15: error: 'a' undeclared (first use in this function) 9 | printf("%d\n",a+m+c); | ^ main.c:9:15: note: each undeclared identifier is reported only once for each function it appears in
s011132806
p00310
C
#include<stdio.h> imt main() { int p,m,c; scanf("%d %d %d",&p,&m,&c); printf("%d\n",p+m+c); return 0; }
main.c:3:1: error: unknown type name 'imt'; did you mean 'int'? 3 | imt main() | ^~~ | int
s488698287
p00310
C
#include<stdio.h> imt main() { int p,m,c; scanf("%d %d %d",&p,&m,&c); printf("%d\n",p+m+c); return 0; }
main.c:3:1: error: unknown type name 'imt'; did you mean 'int'? 3 | imt main() | ^~~ | int
s906173325
p00310
C++
#include<stdio.h> int main(){ int p,m,c; scanf("%d %d %d",&p,&m&c); printf("%d",p+m+c); return 0; }
a.cc: In function 'int main()': a.cc:4:27: error: invalid operands of types 'int*' and 'int' to binary 'operator&' 4 | scanf("%d %d %d",&p,&m&c); | ~~^~ | | | | | int | int*
s775299152
p00310
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
s357039132
p00310
C++
#include "bits/stdc++.h" using namespace std; using ll = long long; using ull = unsigned long long; typedef pair<int, int>pi; typedef pair<ll, ll> P; typedef pair<ll, P> PP; typedef pair<P, P> PPP; const ll MOD = 1e9 + 7; const ll INF = 9e18; const double DINF = 5e14; const double eps = 1e-10; const int di[4] = { 1,...
a.cc: In function 'int main()': a.cc:28:23: error: no match for 'operator>' (operand types are 'std::basic_istream<char>::__istream_type' {aka 'std::basic_istream<char>'} and 'int') 28 | cin >> a >> b > c; | ~~~~~~~~~~~~~ ^ ~ | | | | | int...
s541976509
p00310
C++
#include <iostream> using namespace std; int main(){ int p,m,c; cin>>p>>m>>c; cout<<p+m+c<<endl: }
a.cc: In function 'int main()': a.cc:6:21: error: expected ';' before ':' token 6 | cout<<p+m+c<<endl: | ^ | ;
s369569364
p00310
C++
#include<iostream> using namespace std; int main() { int p, m, c, ans; cin >> p >> m >> c; /* 参加人数の計算 */ ans = p + m + c; /* 参加人数 = プログラム人数 + モバイル人数 + CG人数 */ cout << ans << endl; return 0;
a.cc: In function 'int main()': a.cc:14:18: error: expected '}' at end of input 14 | return 0; | ^ a.cc:4:12: note: to match this '{' 4 | int main() { | ^
s987972511
p00310
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
s737946779
p00310
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
s586722830
p00310
C++
#include <iostream> using namespace std; int main(){ int p,m,c; cout >> p+m+c >> endl; }
a.cc: In function 'int main()': a.cc:7:8: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'int') 7 | cout >> p+m+c >> endl; | ~~~~ ^~ ~~~~~ | | | | | int | std::ostream {aka std::basic_ostream<char>} a.cc:7:8...
s488089557
p00310
C++
#include<iostream> using namespace std; int main() { int a, b, c; cin a >> b >> c; int m; m = a+b+c; cout << m << endl; return 0; }
a.cc: In function 'int main()': a.cc:5:8: error: expected ';' before 'a' 5 | cin a >> b >> c; | ^~ | ;
s237226499
p00310
C++
#include <iostream> using namespace std; int main(){ int p,m,c; cin >> p >> m >> c; cout >> p+m+c >> endl; }
a.cc: In function 'int main()': a.cc:8:8: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'int') 8 | cout >> p+m+c >> endl; | ~~~~ ^~ ~~~~~ | | | | | int | std::ostream {aka std::basic_ostream<char>} a.cc:8:8...
s986595871
p00310
C++
#include<iostream> using namespace std; int main() { int a, b, c; cin a >> b >> c; int m; m = a+b+c; cout << m << endl; return 0; }
a.cc: In function 'int main()': a.cc:5:8: error: expected ';' before 'a' 5 | cin a >> b >> c; | ^~ | ;
s691680495
p00310
C++
#include <iostream> using namespace std; int main(){ int p,m,c; cin >> p >> m >> c; cout >> p+m+c >> endl; return 0; }
a.cc: In function 'int main()': a.cc:8:8: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'int') 8 | cout >> p+m+c >> endl; | ~~~~ ^~ ~~~~~ | | | | | int | std::ostream {aka std::basic_ostream<char>} a.cc:8:8...
s241451133
p00310
C++
#include<iostream> using namespace std; int main() { int ; a, b, c; cin a >> b >> c; int m; m = a+b+c; cout << m << endl; return 0; }
a.cc: In function 'int main()': a.cc:4:5: error: declaration does not declare anything [-fpermissive] 4 | int ; a, b, c; | ^~~ a.cc:4:11: error: 'a' was not declared in this scope 4 | int ; a, b, c; | ^ a.cc:4:14: error: 'b' was not declared in this scope 4 | int ; a, b...
s315271139
p00310
C++
#include<iostream> using namespace std; int main() { int a,b,c; cin a >> b >> c; int m; m = a+b+c; cout << m << endl; return 0; }
a.cc: In function 'int main()': a.cc:5:8: error: expected ';' before 'a' 5 | cin a >> b >> c; | ^~ | ;
s580452149
p00310
C++
#include<iostream> #include<string> int main(){ string x; int n =x.size(); int i; for(i=0;i<n;i++){ cin >> str[i]; } for (i=n;i>0;i--){ cout << str[i] << endl; }return 0; }
a.cc: In function 'int main()': a.cc:5:3: error: 'string' was not declared in this scope 5 | string x; | ^~~~~~ a.cc:5:3: note: suggested alternatives: In file included from /usr/include/c++/14/iosfwd:41, from /usr/include/c++/14/ios:40, from /usr/include/c++/14/ostream:4...
s274401091
p00310
C++
#include<iostream> using namespace std; int main(){ int p; int m; int c; cin >> p >> m >> c ; cout << p + m + c endl; return0; }
a.cc: In function 'int main()': a.cc:10:19: error: expected ';' before 'endl' 10 | cout << p + m + c endl; | ^~~~~ | ; a.cc:12:2: error: 'return0' was not declared in this scope 12 | return0; | ^~~~~~~
s330588029
p00310
C++
#include<iostream> #include<string> int main(){ string x; int n =x.size(); int i; for(i=0;i<n;i++){ cin >> str[i]; } for (i=n;i>0;i--){ cout << str[i] << endl; }return 0; }
a.cc: In function 'int main()': a.cc:5:3: error: 'string' was not declared in this scope 5 | string x; | ^~~~~~ a.cc:5:3: note: suggested alternatives: In file included from /usr/include/c++/14/iosfwd:41, from /usr/include/c++/14/ios:40, from /usr/include/c++/14/ostream:4...
s243747516
p00310
C++
#include<iostream> using namespace std; int main(){ int p, m, c; cin >> p >> m >> c ; cout << p + m + c endl; return0; }
a.cc: In function 'int main()': a.cc:8:19: error: expected ';' before 'endl' 8 | cout << p + m + c endl; | ^~~~~ | ; a.cc:10:2: error: 'return0' was not declared in this scope 10 | return0; | ^~~~~~~
s043329278
p00310
C++
#include <iostream> using namespace std; int main(){ int a, b, c cin >> a >> b >> c; c = a + b + c; cout << c << endl; return 0; }
a.cc: In function 'int main()': a.cc:6:5: error: expected initializer before 'cin' 6 | cin >> a >> b >> c; | ^~~ a.cc:7:3: error: 'c' was not declared in this scope 7 | c = a + b + c; | ^
s251525550
p00310
C++
#include <iostream> using namespace std; int main(){ int p, m, c cin >> p >> m >> c; c = p + m + c; cout << c << endl; return 0; }
a.cc: In function 'int main()': a.cc:6:5: error: expected initializer before 'cin' 6 | cin >> p >> m >> c; | ^~~ a.cc:7:3: error: 'c' was not declared in this scope 7 | c = p + m + c; | ^
s432383594
p00310
C++
#include<iostream> using namespace std; int main() { int p,m,i; cin >> p >> m >> i; cout << p+m+i <<< endl; return 0; }
a.cc: In function 'int main()': a.cc:7:17: error: expected primary-expression before '<' token 7 | cout << p+m+i <<< endl; | ^
s943212554
p00310
C++
#include<iostream> using namespace std; int main() { int p,m,i; cin >> p >> m >> i; cout << p+m+i <<< endl; return 0; }
a.cc: In function 'int main()': a.cc:7:17: error: expected primary-expression before '<' token 7 | cout << p+m+i <<< endl; | ^
s366433549
p00310
C++
#include <bits/stdc++.h> using namespace std; int p, m, c; int main() { cin >> n >> m >> c; cout << n + m + c << endl; }
a.cc: In function 'int main()': a.cc:6:16: error: 'n' was not declared in this scope; did you mean 'yn'? 6 | cin >> n >> m >> c; | ^ | yn
s787357709
p00310
C++
#include<stdio.h> #include<iostream> using namespace std; int main(void){ int p,m,c,ans; cin >> p >> m >> c >>endl; ans = p + c + m; cout << ans; return 0; }
a.cc: In function 'int main()': a.cc:6:29: error: no match for 'operator>>' (operand types are 'std::basic_istream<char>::__istream_type' {aka 'std::basic_istream<char>'} and '<unresolved overloaded function type>') 6 | cin >> p >> m >> c >>endl; | ~~~~~~~~~~~~~~~~~~~~^~~~~~ In file included ...
s489157197
p00310
C++
#include "bits/stdc++.h" using namespace std; int main(){ int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; } int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; }
a.cc:10:3: error: 'cin' does not name a type 10 | cin>>a>>b>>c; | ^~~ a.cc:11:3: error: 'cout' does not name a type 11 | cout<<a+b+c<<endl; | ^~~~ a.cc:12:3: error: expected unqualified-id before 'return' 12 | return 0; | ^~~~~~ a.cc:13:1: error: expected declaration before '}' to...
s197216696
p00310
C++
#include <bits/stdc++.h> using namespace std; int main(){ int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; } int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; }
a.cc:10:3: error: 'cin' does not name a type 10 | cin>>a>>b>>c; | ^~~ a.cc:11:3: error: 'cout' does not name a type 11 | cout<<a+b+c<<endl; | ^~~~ a.cc:12:3: error: expected unqualified-id before 'return' 12 | return 0; | ^~~~~~ a.cc:13:1: error: expected declaration before '}' to...
s537300681
p00310
C++
#include <bits/stdc++.h> using namespace std; int main(){ int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; } int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; }
a.cc:10:3: error: 'cin' does not name a type 10 | cin>>a>>b>>c; | ^~~ a.cc:11:3: error: 'cout' does not name a type 11 | cout<<a+b+c<<endl; | ^~~~ a.cc:12:3: error: expected unqualified-id before 'return' 12 | return 0; | ^~~~~~ a.cc:13:1: error: expected declaration before '}' to...
s661006528
p00310
C++
#include "bits/stdc++.h" using namespace std; int main(){ int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; } int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; }
a.cc:10:3: error: 'cin' does not name a type 10 | cin>>a>>b>>c; | ^~~ a.cc:11:3: error: 'cout' does not name a type 11 | cout<<a+b+c<<endl; | ^~~~ a.cc:12:3: error: expected unqualified-id before 'return' 12 | return 0; | ^~~~~~ a.cc:13:1: error: expected declaration before '}' to...
s740558564
p00310
C++
#include "bits/stdc++.h" using namespace std; int main(){ int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; } int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; return 0; }
a.cc:10:3: error: 'cin' does not name a type 10 | cin>>a>>b>>c; | ^~~ a.cc:11:3: error: 'cout' does not name a type 11 | cout<<a+b+c<<endl; | ^~~~ a.cc:12:3: error: expected unqualified-id before 'return' 12 | return 0; | ^~~~~~ a.cc:13:1: error: expected declaration before '}' to...
s721197079
p00310
C++
#include <stdio.h> #define rep(i, n) for(int i = 0; i < n; ++i) int main(void) { int n, ans = 0, i; rep(i, 3) { scanf("%d", &n); ans += m; } printf("%d\n", ans); return 0; }
a.cc: In function 'int main()': a.cc:8:12: error: 'm' was not declared in this scope 8 | ans += m; | ^
s202899625
p00310
C++
include <bits/stdc++.h> using namespace std; int main(){ int p,m,c; cin>>p>>m>>c; cout << p+m+c <<endl; return 0; }
a.cc:1:1: error: 'include' does not name a type 1 | include <bits/stdc++.h> | ^~~~~~~ a.cc: In function 'int main()': a.cc:6:9: error: 'cin' was not declared in this scope 6 | cin>>p>>m>>c; | ^~~ a.cc:7:9: error: 'cout' was not declared in this scope 7 | cout << p+m+c <<e...
s840580110
p00310
C++
#include<bits/stdc++.h> using namespace std; int main(){ int p,m,c; cin>>p>>m>>c cout<<p+m+c<<endl; return 0; }
a.cc: In function 'int main()': a.cc:6:17: error: expected ';' before 'cout' 6 | cin>>p>>m>>c | ^ | ; 7 | cout<<p+m+c<<endl; | ~~~~
s373791192
p00310
C++
#include <bits/stdc++.h> using namespace std: int main(){ int p,m,c; cin>>p>>m>>c; cout<<p + m + c<<endl; return 0; }
a.cc:3:20: error: expected ';' before ':' token 3 | using namespace std: | ^ | ; a.cc:3:20: error: expected unqualified-id before ':' token
s466082648
p00310
C++
#include <iostream> using namespace std; int main() { int p, m, c; cin << p << m << c; cout << p + m + c << endl; return 0; }
a.cc: In function 'int main()': a.cc:5:26: error: no match for 'operator<<' (operand types are 'std::istream' {aka 'std::basic_istream<char>'} and 'int') 5 | int p, m, c; cin << p << m << c; | ~~~ ^~ ~ | | | | | int ...
s736653350
p00311
C
#include <stdio.h> int main(void) { int ha,hb,ka,kb,a,b,c,d,ht,kt; scanf("%d %d",&ha,&hb); scanf("%d %d",&ka,&kb); scanf("%d %d %d %d",&a,&b,&c,&d); ht=ha*a+hb*b; if(ha<=10) ht+=(ha/10)*c; if(hb<=20) ht+=(hb/20)*d; kt=ka*a+kb*b; if(ka<=10) kt+=(ka/10)*c; if(kb<=...
main.c:25:1: error: expected identifier or '(' before '}' token 25 | } | ^
s044234695
p00311
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
s225152935
p00311
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
s733084240
p00311
C
#include<stdio.h> int main(void) { int h1,h2,k1,k2,a,b,c,d,f,g; scanf("%d%d%d%d%d%d%d%d",&h1,&h2,&k1,&k2,&a,&b,&c,&d)+ f=a*h1+h1/10*c+b*h2+h2/20*d; g=a*k1+k1/10*c+b*k2+k2/20*d; if(f>g) { printf("hiroshi\n"); } else if(f<g) { printf("kenjiro\n"); } else { printf("even\n"); ...
main.c: In function 'main': main.c:6:10: error: lvalue required as left operand of assignment 6 | f=a*h1+h1/10*c+b*h2+h2/20*d; | ^
s767365718
p00311
C
#include <stdio.h> int main(){ int k1,k2,h1,h2,a,b,c,d,x,y; scanf("%d%d",&h1,&h2); scanf("%d%d",&k1,&k2); scanf("%d%d%d%d",&a,&b,&c,&d); x=((h1*a)+(h1/10*c))+((h2*b)+(h2/20*d)); y=((k1*a)+(k1/10*c))+((k2*b)+(k2/20*d)) if(x>y){ printf("hiroshi\n"); }else if(x<y){ printf("kenjiro\n"); }else{ printf("even\n"); } return 0...
main.c: In function 'main': main.c:9:40: error: expected ';' before 'if' 9 | y=((k1*a)+(k1/10*c))+((k2*b)+(k2/20*d)) | ^ | ; 10 | if(x>y){ | ~~
s311654479
p00311
C
#include <stdio.h> int main(void) { int a[7]; int hiroshi,kenjiro; int i; for(i = 0;i <= 7;i++){ scanf("&d",&n); } hiroshi = a[0] * a[4] + (a[0] / 10) * a[6] + a[1] * a[5] + (a[1] / 20) * a[7]; kenjiro = a[2] * a[4] + (a[2] / 10) * a[6] + a[3] * a[5] + (a[3] / 20) * a[7]; if(hir...
main.c: In function 'main': main.c:8:21: error: 'n' undeclared (first use in this function) 8 | scanf("&d",&n); | ^ main.c:8:21: note: each undeclared identifier is reported only once for each function it appears in
s603104848
p00311
C
#include<stdio.h> int main(void) { ????????int h1,h2,k1,k2,a,b,c,d,H,K; ????????scanf ("%d%d",&h1,&h2); ????????scanf ("%d%d",&k1,&k2); ????????scanf ("%d%d%d%d",&a,&b,&c,&d); ????????H=h1*a+h2*b+(h1/10)*c+(h2/20)*d; ????????K=k1*a+k2*b+(k1/10)*c+(k2/20)*d; ????????if (H>K) ????????printf ("hiroshi\n"); ????????else if...
main.c: In function 'main': main.c:4:1: error: expected expression before '?' token 4 | ????????int h1,h2,k1,k2,a,b,c,d,H,K; | ^ main.c:5:1: error: expected expression before '?' token 5 | ????????scanf ("%d%d",&h1,&h2); | ^ main.c:5:24: error: 'h1' undeclared (first use in this function) 5 | ??...
s840206044
p00311
C
include<stdio.h> int main(int argc, char const *argv[]) { int h1,h2,k1,k2,a,b,c,d; int m,n; scanf("%d%d%d%d%d%d%d%d",&h1,&h2,&k1,&k2,&a,&b,&c,&d); m = h1*a+h2*b+(h1/10)*c+(h2/20)*d; n = k1*a+k2*b+(k1/10)*c+(k2/20)*d; if (m > n) { /* code */ printf("hiroshi\n"); } else if (m < n) { ...
main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token 1 | include<stdio.h> | ^
s632951969
p00311
C++
#include bits/stdc++.h> using namespace std; int main(){ int h,hh; int k,kk; int a,b,c,d; cin>>h>>hh>>k>>kk; cin>>a>>b>>c>>d; int x=(a*h+c*(h/10))+(b*hh+d*(hh/10)); int y=(a*k+c*(k/10))+(b*kk+d*(kk/10)); if(x==y){ cout<<“even”<<endl; }else if(x>y){ cout<<“hiroshi”<<en...
a.cc:1:10: error: #include expects "FILENAME" or <FILENAME> 1 | #include bits/stdc++.h> | ^~~~ a.cc:12:15: error: extended character “ is not valid in an identifier 12 | cout<<“even”<<endl; | ^ a.cc:12:15: error: extended character ” is not valid in an identifier a.cc:1...
s726609275
p00311
C++
#include <bits/stdc++.h> using namespace std; int main(){ int h,hh; int k,kk; int a,b,c,d; cin>>h>>hh>>k>>kk; cin>>a>>b>>c>>d; int x=(a*h+c*(h/10))+(b*hh+d*(hh/10)); int y=(a*k+c*(k/10))+(b*kk+d*(kk/10)); if(x==y){ cout<<“even”<<endl; }else if(x>y){ cout<<“hiroshi”<<e...
a.cc:12:15: error: extended character “ is not valid in an identifier 12 | cout<<“even”<<endl; | ^ a.cc:12:15: error: extended character ” is not valid in an identifier a.cc:14:15: error: extended character “ is not valid in an identifier 14 | cout<<“hiroshi”<<endl; | ...
s509191911
p00311
C++
#include <bits/stdc++.h> using namespace std; int main(){ int h,hh; int k,kk; int a,b,c,d; cin>>h>>hh>>k>>kk; cin>>a>>b>>c>>d; int x=(a*h+c*(h/10))+(b*hh+d*(hh/10)); int y=(a*k+c*(k/10))+(b*kk+d*(kk/10)); if(x==y){ cout<<“even”<<endl; }else if(x>y){ cout<<“hiroshi”<<e...
a.cc:12:15: error: extended character “ is not valid in an identifier 12 | cout<<“even”<<endl; | ^ a.cc:12:15: error: extended character ” is not valid in an identifier a.cc:14:15: error: extended character “ is not valid in an identifier 14 | cout<<“hiroshi”<<endl; | ...
s793342226
p00311
C++
#include <iostream> #include <vector> #include <algorithm> using namespace std; int main() { int h1, h2, k1, k2; cin >> h1 >> h2 >> k1 >> k2; int a, b, c, d; cin >> a >> b >> c >> d; auto calc = [&](int h, int k) { int score = h * a + k * b; score += c * (h / 10); ...
a.cc:26:2: error: #error "a" 26 | #error "a" | ^~~~~
s254550004
p00311
C++
#include<iostream> using namespace std; int main(){ int a, b, c, d; cin >> a >> b >> c >> d; int e, f, g, h; cin >> e >> f >> g >> h; int h = a*e + (a / 10)*g + b*f + (b / 10)*h; int k = c*e + (c / 10)*g + d*f + (d / 10)*h; if (h > k)cout << "hiroshi\n"; else if (h < k)cout << "kenjiro\n"; else cout << "even\n";...
a.cc: In function 'int main()': a.cc:6:13: error: redeclaration of 'int h' 6 | int h = a*e + (a / 10)*g + b*f + (b / 10)*h; | ^ a.cc:5:22: note: 'int h' previously declared here 5 | int e, f, g, h; cin >> e >> f >> g >> h; | ^
s748636508
p00311
C++
#include <iostream> using namespace std; int main(){ int h1, h2, k1, k2, a, b, c, d, h, k; cin >> h1 >> h2; cin >> k1 >> k2; cin >> a >> b >> c >> d; h = h1*a + h1/10*c + h2*b + h2/10*d; k = k1*a + k1/10*c + k2*b + k2/10*d; if(hr > k){ cout << "hiroshi" << endl; } else if(...
a.cc: In function 'int main()': a.cc:13:8: error: 'hr' was not declared in this scope; did you mean 'h'? 13 | if(hr > k){ | ^~ | h
s496787785
p00311
C++
#include <iostream> using namespace std; int main(){ int h1, h2, k1, k2, a, b, c, d, h, k; cin >> h1 >> h2; cin >> k1 >> k2; cin >> a >> b >> c >> d; h = h1*a + h1/10*c + h2*b + h2/10*d; k = k1*a + k1/10*c + k2*b + k2/10*d; if(hr > k){ cout << "hiroshi" << endl; } else if(...
a.cc: In function 'int main()': a.cc:13:8: error: 'hr' was not declared in this scope; did you mean 'h'? 13 | if(hr > k){ | ^~ | h
s026975733
p00311
C++
#include <iostream> using namespace std; int main(){ int h1, h2, k1, k2, a, b, c, d, h, k; cin >> h1 >> h2; cin >> k1 >> k2; cin >> a >> b >> c >> d; h = h1*a + h1/10*c + h2*b + h2/10*d; k = k1*a + k1/10*c + k2*b + k2/10*d; if(hr > k){ cout << "hiroshi" << endl; } else if(...
a.cc: In function 'int main()': a.cc:13:8: error: 'hr' was not declared in this scope; did you mean 'h'? 13 | if(hr > k){ | ^~ | h
s940592223
p00311
C++
#include "bits/stdc++.h"/*????????¬(?¶??????????)*/ using namespace std;/*????????¬(?¶??????????)*/ int main() { int hh; int hhh; int kk; int kkk; int a; int b; int c; int d; cin >> hh >> hhh; cin >> kk >> kkk; cin >> a >> b >> c >> d; cout << a + b + c << endl; int hiro = (hh * a) + (hhh * b) +((hh / 1...
a.cc: In function 'int main()': a.cc:22:34: error: 'hiroshi' was not declared in this scope; did you mean 'hiro'? 22 | if(hiro > kenji) cout << hiroshi <<endl; | ^~~~~~~ | hiro a.cc:23:34: error: 'kenjiro' was not declared in this ...