submission_id stringlengths 10 10 | problem_id stringlengths 6 6 | language stringclasses 3
values | code stringlengths 1 522k | compiler_output stringlengths 43 10.2k |
|---|---|---|---|---|
s684796671 | p00499 | C | #include <stdio.h>
main(){
int hi,koku,suu,kokud,suud;
int n=0,m=0;
scanf("%d",&hi);
scanf("%d",&koku);
scanf("%d",&suu);
scanf("%d",&kokud);
scanf("%d",&suud);
printf("\n");
while(1){
koku-=kokud;
n++;
if(koku<=0) break;
return 0;
}
while(1){
suu-=suud;
m++;
if(suu<=0) break
return 0;
}
if(n>=m... | main.c:3:1: error: return type defaults to 'int' [-Wimplicit-int]
3 | main(){
| ^~~~
main.c: In function 'main':
main.c:25:17: error: expected ';' before 'return'
25 | if(suu<=0) break
| ^
| ;
26 | return 0;
| ~~~~~~
|
s538647557 | p00499 | C | #include <stdio.h>
int main()
{
int L, a, b, c, d;
int M, N;
scanf("%d\n%d\n%d\n%d\n%d\n",&L, &a, &b, &c, &d);
M = a/c;
N = b/d;
if(a % c != 0)
M++;
if(b % d != 0)
N++;
if(M > N)
printf("%d\n", L - M)
else
printf("%d\n", L - N)
return... | main.c: In function 'main':
main.c:15:30: error: expected ';' before 'else'
15 | printf("%d\n", L - M)
| ^
| ;
16 | else
| ~~~~
|
s824419524 | p00499 | C | max(x,y){return (x>y?x:y);}l,a,b,c;main(d){scanf("%d%d%d%d%d",&l,&a,&b,&c,&d);k=!printf("%d\n",l-max(a/c+!!(a%c),b/d+!!(b%d)));} | main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
1 | max(x,y){return (x>y?x:y);}l,a,b,c;main(d){scanf("%d%d%d%d%d",&l,&a,&b,&c,&d);k=!printf("%d\n",l-max(a/c+!!(a%c),b/d+!!(b%d)));}
| ^~~
main.c: In function 'max':
main.c:1:1: error: type of 'x' defaults to 'int' [-Wimplicit-int]
main.c:1:1: ... |
s438567499 | p00499 | C++ | #include <iostream>
using namespace std;
int main() {
int h, j, m, j1,m1, x, y;
cin >> h >> j >> m >> j1 >> m1;
if(j%j1 >= 1){
x = j/j1 + 1
}
else{
x = j/j1
}
if(m%m1 >= 1){
x = m/m1 + 1
}
else{
x = m/m1
}
cout << h - max(x,y) << endl;
return 0;
}
| a.cc: In function 'int main()':
a.cc:9:21: error: expected ';' before '}' token
9 | x = j/j1 + 1
| ^
| ;
10 | }
| ~
a.cc:12:17: error: expected ';' before '}' token
12 | x = j/j1
| ^
| ... |
s486596097 | p00499 | C++ | #include <iostream>
using namespace std;
int main() {
int h, j, m, j1,m1, x, y;
cin >> h >> j >> m >> j1 >> m1;
if(j%j1 >= 1){
x = j/j1 + 1;
}
else{
x = j/j1;
}
if(m%m1 >= 1){
x = m/m1 + 1;
}
else{
x = m/m1;
}
int z =max(x,y)
cout << h - z << endl;
return 0;
}
| a.cc: In function 'int main()':
a.cc:24:3: error: expected ',' or ';' before 'cout'
24 | cout << h - z << endl;
| ^~~~
|
s446906526 | p00499 | C++ | #include<iostream>
#include<cstdio>
using namespace std;
int main(){
int L,A,B,C,D,day[2];
cin >> L >> A >> B >> C >> D;
day[0] = A/C;
if(day[0]*C != A){
day[0]++;
}
day[1] = B/D;
if(day[1]*D != B){
day[1]++;
}
sort(day,day+1);
cout << L-day[0] << endl;
} | a.cc: In function 'int main()':
a.cc:18:3: error: 'sort' was not declared in this scope; did you mean 'short'?
18 | sort(day,day+1);
| ^~~~
| short
|
s431132099 | p00499 | C++ | #include <iostream>
#include <algorithm>
using namespace std;
int main(){
int l, a, b, c, d; cin >> l >> a >> b >> c >> d;
cout << (l - max(a / c + !!(a % c), b / d + !!(b % d)) << endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:6:60: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
6 | cout << (l - max(a / c + !!(a % c), b / d + !!(b % d)) << endl;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
a.cc:6:67: error: ex... |
s721900150 | p00499 | C++ | #include<iostream>
using namespace std;
int main(){
int a;
int i;
int u;
int e;
int o;
int ka;
int ki;
cin>>a>>i>>u>>e>>o;
ka=i/e;
if(i%e>0){
ka=ka+1;
}
ki=u/o;
if(u%o>0){
ki=ki+1;
}
cout<<a-ka-ki<,endl;
} | a.cc: In function 'int main()':
a.cc:23:17: error: expected primary-expression before ',' token
23 | cout<<a-ka-ki<,endl;
| ^
|
s593277234 | p00499 | C++ | #include<iostream>
using namespace std;
int main(){
int a;
int i;
int u;
int e;
int o;
int ka;
int ki;
cin>>a>>i>>u>>e>>o;
ka=i/e;
if(i%e>0){
ka=ka+1;
}
ki=u/o;
if(u%o>0){
ki=ki+1;
}
cout<<a-ka-ki<endl;
} | a.cc: In function 'int main()':
a.cc:23:16: error: no match for 'operator<' (operand types are 'std::basic_ostream<char>' and '<unresolved overloaded function type>')
23 | cout<<a-ka-ki<endl;
| ~~~~~~~~~~~~~^~~~~
In file included from /usr/include/c++/14/string:48,
from /usr/include/c++/14... |
s122570410 | p00499 | C++ | #include<iostream>
using namespace std;
int main(){
int a;
int i;
int u;
int e;
int o;
int ka;
int ki;
cin>>a>>i>>u>>e>>o;
ka=i/e;
if(i%e>0){
ka=ka+1;
}
ki=u/o;
if(u%o>0){
ki=ki+1;
}
if(ka>ki){
cout<<a-ka<<endl;
}else{
cout<<a-ki<<endl;
} | a.cc: In function 'int main()':
a.cc:26:2: error: expected '}' at end of input
26 | }
| ^
a.cc:4:11: note: to match this '{'
4 | int main(){
| ^
|
s510744037 | p00499 | C++ | #include <stdio.h>
int main(void)
{
float l,a,b,c,d,e,f,z;
l,a,b,c,d,e,f,z=0;
scanf("%f",&l);
scanf("%f",&a);
scanf("%f",&b);
scanf("%f",&c);
scanf("%f",&d);
e=(a/c)-(a%c);
f=(b/d)-(b%d);
if(a%c=0)(e<f){z=l-f};
if(b%d=0)(f<e){z=l-e};
if(a%c!=0)(e<f){z=l-f-1};
if(b%d!=0)(f<e){z=l-e-1};
printf("%f\n",... | a.cc: In function 'int main()':
a.cc:14:19: error: invalid operands of types 'float' and 'float' to binary 'operator%'
14 | e=(a/c)-(a%c);
| ~^~
| | |
| | float
| float
a.cc:15:19: error: invalid operands of types 'fl... |
s300234416 | p00499 | C++ | #include <stdio.h>
float main(void)
{
float l,a,b,c,d,e,f,v,w,x,y,z;
l,a,b,c,d,e,f,v,w,x,y,z=0;
scanf("%f",&l);
scanf("%f",&a);
scanf("%f",&b);
scanf("%f",&c);
scanf("%f",&d);
if(a%c=0){v=l-a/c};
if(b%d=0){w=l-b/d};
if(a%c!=0){x=l-1-a/c};
if(b%d!=0){y=l-1-b/d};
if(v<w){w=z};
if(w<v){v=z};
i... | a.cc:3:1: error: '::main' must return 'int'
3 | float main(void)
| ^~~~~
a.cc: In function 'int main()':
a.cc:14:13: error: invalid operands of types 'float' and 'float' to binary 'operator%'
14 | if(a%c=0){v=l-a/c};
| ~^~
| | |
| | float
| ... |
s600380611 | p00499 | C++ | #include <stdio.h>
int main() {
int A, B, C, D, L, i, R, cnt = 0;
scanf( "%d", &L );
scanf( "%d", &A );
scanf( "%d", &B );
scanf( "%d", &C );
scanf( "%d", &D );
for( ;; ) {
A -= C;
B -= D;
cnt++;
if( A <= 0 && B <= 0 ) break;
}
R = L - cnt;
printf( "%d\n", R );
return 0; | a.cc: In function 'int main()':
a.cc:18:11: error: expected '}' at end of input
18 | return 0;
| ^
a.cc:3:12: note: to match this '{'
3 | int main() {
| ^
|
s849621351 | p00499 | C++ | #include <stdio.h>
int main() {
int A, B, C, D, L, i, R, cnt = 0;
scanf( "%d", &L );
scanf( "%d", &A );
scanf( "%d", &B );
scanf( "%d", &C );
scanf( "%d", &D );
for( ;; ) {
A -= C;
B -= D;
cnt++;
if( A <= 0 && B <= 0 ) break;
}
R = L - cnt;
printf( "%d\n", R );
return 0; | a.cc: In function 'int main()':
a.cc:18:11: error: expected '}' at end of input
18 | return 0;
| ^
a.cc:3:12: note: to match this '{'
3 | int main() {
| ^
|
s810589723 | p00499 | C++ | #include <stdio.h>
int main(){
int a, b, c, d, l, z ;
double e, f;
scanf("%d %d %d %d %d", &l, &a, &b, &c, &d,);
e = a/c;
double ceil(double e);
f = b/d;
double ceil(double f);
if(e>=f){
z = l-e;
}else{
z =l-f;
}
printf("%d\n", z);
return 0;
} | a.cc: In function 'int main()':
a.cc:5:46: error: expected primary-expression before ')' token
5 | scanf("%d %d %d %d %d", &l, &a, &b, &c, &d,);
| ^
|
s739789760 | p00499 | C++ | #include <stdio.h>
int main(){
int a, b, c, d, l, z ;
int e, f;
scanf("%d %d %d %d %d", &l, &a, &b, &c, &d);
e =double ceil( a/c);
f =double ceil(b/d);
if(e>=f){
z = l-e;
}else{
z =l-f;
}
printf("%d\n", z);
return 0;
} | a.cc: In function 'int main()':
a.cc:6:6: error: expected primary-expression before 'double'
6 | e =double ceil( a/c);
| ^~~~~~
a.cc:7:6: error: expected primary-expression before 'double'
7 | f =double ceil(b/d);
| ^~~~~~
|
s548158643 | p00499 | C++ | #include <stdio.h>
int main(){
int a, b, c, d, l, z ;
int e, f;
scanf("%d %d %d %d %d", &l, &a, &b, &c, &d);
e = ceil((double)a/(double)c);
f = ceil((double)b/(double)d);
if(e>=f){
z = l-e;
}else{
z =l-f;
}
printf("%d\n", z);
return 0;
} | a.cc: In function 'int main()':
a.cc:6:7: error: 'ceil' was not declared in this scope
6 | e = ceil((double)a/(double)c);
| ^~~~
|
s413990787 | p00499 | C++ | include <stdio.h>
int main(){
int l,a,b,c,d,p,i;
scanf("%d %d %d %d %d",&l,&a,&b,&c,&d);
for(i = 1 ; a > c || b > d ; i++){
a = a-c;
b = b-d;
}
p = l - i;
printf("%d\n",p);
return 0;
} | a.cc:1:1: error: 'include' does not name a type
1 | include <stdio.h>
| ^~~~~~~
|
s932733186 | p00499 | C++ | #include<iostream>
using namespace std;
int main () {
int a,b,c,d,L;
int hi,tuki;
float fhi,ftuki;
cin >> L >> a >> b >> c >> d;
hi=a/c;
fhi=(float)a/c;
tuki=b/d;
ftuki=(float)b/d;
if(hi<fhi){
thi++;
}
if(tuki<ftuki){
ftuki++;
}
if(hi>tuki){
cout << L-hi <<'\n';
}else{
cout << L-tuki <<'\n';
... | a.cc: In function 'int main()':
a.cc:14:17: error: 'thi' was not declared in this scope; did you mean 'fhi'?
14 | thi++;
| ^~~
| fhi
|
s495890576 | p00499 | C++ | #include<iostream>
using namespace std;
int main()
{
int L,A,B,C,D,K,E,F;
cin>>L>>A>>B>>C>>D;
E=A/C;
F=B/D;
if(A%C>0){
E+=1;
}
if(B%D>0){
F+=1;
}
if(E<F){
K=L-E;
}
else(E>F){
K=L-F;
}
cout<<K<<'\n';
return 0;
} | a.cc: In function 'int main()':
a.cc:19:10: error: expected ';' before '{' token
19 | else(E>F){
| ^
| ;
|
s697844382 | p00499 | C++ | #include<iostream>
using namespace std;
int main()
{
int L,A,B,C,D,K,E,F;
cin>>L>>A>>B>>C>>D;
E=A/C;
F=B/D;
if(A%C>0){
E+=1;
}
if(B%D>0){
F+=1;
}
if(E<F){
K=L-E;
}
else(E>F)
K=L-F;
cout<<K<<'\n';
return 0;
} | a.cc: In function 'int main()':
a.cc:19:10: error: expected ';' before 'K'
19 | else(E>F)
| ^
| ;
20 | K=L-F;
| ~
|
s195499193 | p00499 | C++ | #include<iostream>
using namespace std;
int main()
{
int l;
cin>>l;
2<=l&&l<=40;
int a;
cin>>a;
1<=a&&a<=1000;
int b;
cin>>b;
1<=b&&b<=1000;
int c;
cin>>c;
1<=c&&c<=100;
int d;
cin>>d;
1<=d&&d<=100;
double jpn;
jpn=a%c;
double math;
math=b%d;
if(jpn>0){
if(math>0){
if(jpn+math>1.0)... | a.cc: In function 'int main()':
a.cc:84:2: error: expected '}' at end of input
84 | }
| ^
a.cc:5:1: note: to match this '{'
5 | {
| ^
|
s557870643 | p00499 | C++ | #include<iostream>
using namespace std;
int main()
{
int l;
cin>>l;
2<=l&&l<=40;
int a;
cin>>a;
1<=a&&a<=1000;
int b;
cin>>b;
1<=b&&b<=1000;
int c;
cin>>c;
1<=c&&c<=100;
int d;
cin>>d;
1<=d&&d<=100;
int jpn;
jpn=a%c;
int math;
math=b%d;
if(jpn>0){
if(math>0){
if(jpn+math>1.0)
... | a.cc: In function 'int main()':
a.cc:35:39: error: expected primary-expression before '<<' token
35 | cout<<(l-a/c)+<<"\n";
| ^~
a.cc:53:2: error: expected '}' at end of input
53 | }
| ^
a.cc:5:1: note: to match this '{'
5 | {
| ... |
s782520060 | p00499 | C++ | #include <iostream>
#include <cstdio>
using namespace std;
int main(){
int l(2 <= 40), a(2 <= 1000), b(2 <= 1000), c(2 <= 1000), d(2 <= 1000);
cin >> l >> a >> b >> c >> d;
for (int i; i = 0; i++)
if (a <= 0 && b <= 0)break;
a -= c;
b -= d;
}
cout << l - i << endl;
return 0;
} | a.cc:14:5: error: 'cout' does not name a type
14 | cout << l - i << endl;
| ^~~~
a.cc:16:17: error: expected unqualified-id before 'return'
16 | return 0;
| ^~~~~~
a.cc:17:1: error: expected declaration before '}' token
17 | }
| ^
|
s234042807 | p00499 | C++ | include<iostream>
#include<cstdio>
#include<algorithm>
using namespace std;
int main(){
int l;
int a,b;
int c,d;
int ans;
int j,m;
scanf(" %d %d %d %d %d",&l,&a,&b,&c,&d);
j = m = 0;
if(a%c!=0){
j=1;
}
if(b%d!=0){
m=1;
}
ans = max(a/b+j,b/d+m);
printf("%d\n",l-ans);
return 0;
} | 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/algorithm:60,
from a.cc:3:
/usr/include/c++/14/ext/type_traits.h:164:35: error: 'constexpr const bool __g... |
s742062454 | p00499 | C++ | #include <iostream>
using namespace std;
int main(void){
int L , A , B , C , D;
cin >> L >> A >> B >> C >> D;
int days_jp , days_mt , days;
days_jp = (A / C) + 1;
days_mt = (B / D) + 1;
days = (days_jp > days_mt) ? days_jp : days_mt;
cout << L - daysl;
return 0;
} | a.cc: In function 'int main()':
a.cc:14:15: error: 'daysl' was not declared in this scope; did you mean 'days'?
14 | cout << L - daysl;
| ^~~~~
| days
|
s648913739 | p00499 | C++ | #include<iostream>
using namespace std;
int main() {
int L, A, B, C, D;
int restA = 0, restB = 0;
cin >> L >> A >> B >> C >> D;
if( A % C > 0) { restA = 1;}
if( B % D > 0) { restB = 1;}
cout << L - max((A/C) + restA, (b/D) +restB ) << endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:9:41: error: 'b' was not declared in this scope
9 | cout << L - max((A/C) + restA, (b/D) +restB ) << endl;
| ^
|
s313278092 | p00499 | C++ | #include <iostream>
using namespace std;
int main(void)
{
int a,b,c,d,e,f,g,h,i,j,k;
float A;
cin>>a>>b>>c>>d>>e;
A=b-d;
g=0;
g++;
for (;;)
{
if (A<=0)
{
g++;
break;
}
else if (A>0)
{
g++;
}
}
A=c-e;
f=0;
f++;
for (;;)
{
if (A<=0)
{
f++;
break;
}
A=A-e;
else if (A>0)
... | a.cc: In function 'int main()':
a.cc:34:17: error: 'else' without a previous 'if'
34 | else if (A>0)
| ^~~~
|
s641529155 | p00499 | C++ |
#include <stdio.h>
#include <algorithm>
using namespace std;
int main() {
int n[5];
for (int i = 0; i < 5; i++) {
scanf("%d", &n[i]);
}
printf("%d\n", n[0] - max((int)ceil((double)n[1] / n[3]), (int)ceil((double)n[2] / n[4])));
return 0;
} | a.cc: In function 'int main()':
a.cc:15:40: error: 'ceil' was not declared in this scope
15 | printf("%d\n", n[0] - max((int)ceil((double)n[1] / n[3]), (int)ceil((double)n[2] / n[4])));
| ^~~~
|
s223966269 | p00499 | C++ | #include<iostream>
using namespace std;
int L, A, B, C, D;
int rA = 0, rB = 0;
int main(){
cin >> L >> A >> B >> C >> D;
if( a - (A/C) * C > 0) { rA = 1;}
if( B - (B/D) * D > 0) { rB = 1;}
cout << L - max((A/C) + rA,(B/D) +rB ) << endl;
return0;
} | a.cc: In function 'int main()':
a.cc:7:5: error: 'a' was not declared in this scope
7 | if( a - (A/C) * C > 0) { rA = 1;}
| ^
a.cc:10:1: error: 'return0' was not declared in this scope
10 | return0;
| ^~~~~~~
|
s463525721 | p00499 | C++ | #include<iostream>
using namespace std;
int L, A, B, C, D;
int rA = 0, rB = 0;
int main(){
cin >> L >> A >> B >> C >> D;
if( A - (A/C) * C > 0) { rA = 1;}
if( B - (B/D) * D > 0) { rB = 1;}
cout << L - max((A/C) + rA,(B/D) +rB ) << endl;
return0;
} | a.cc: In function 'int main()':
a.cc:10:1: error: 'return0' was not declared in this scope
10 | return0;
| ^~~~~~~
|
s227652299 | p00499 | C++ | #include <iostream>
#include <algorithm>
int main() {
int l; // ??¬???????????\??°
int a, b, c, d;
int koku, san;
std::cin >> l >> a >> b >> c >> d;
koku = b / d;
san = a / c;
l = l - std::max(koku, san);
std::cout << l << std::endl;
return 0
} | a.cc: In function 'int main()':
a.cc:15:17: error: expected ';' before '}' token
15 | return 0
| ^
| ;
16 | }
| ~
|
s434632850 | p00499 | C++ | #include <iostream>
#include <algorithm>
int main() {
int l; // ??¬???????????\??°
int a, b, c, d;
int koku, san;
std::cin >> l >> a >> b >> c >> d;
koku = b / d;
san = a / c;
l = l - std::max(koku, san);
std::cout << l << std::endl;
return 0
} | a.cc: In function 'int main()':
a.cc:15:17: error: expected ';' before '}' token
15 | return 0
| ^
| ;
16 | }
| ~
|
s206368296 | p00499 | C++ | #include <iostream>
using namespace std;
int main() {
int A, B, C, D, L;
int X, Y;
cin >> L >> A >> B >> C >> D;
X = A/C;
if(A%C != 0)
X++;
Y = B/D;
if(B%D != 0)
Y++;
cout << (X>Y) ? L-X : L-Y << endl;
}
| a.cc: In function 'int main()':
a.cc:17:29: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
17 | cout << (X>Y) ? L-X : L-Y << endl;
| ~~~~^~~~~~~
|
s160587630 | p00499 | C++ | #include <iostream>
using namespace std;
int main() {
int A, B, C, D, L;
int X, Y;
cin >> L >> A >> B >> C >> D;
X = A/C;
if(A%C != 0)
X++;
Y = B/D;
if(B%D != 0)
Y++;
cout << (X>Y) ? (L-X) : (L-Y) << endl;
}
| a.cc: In function 'int main()':
a.cc:17:33: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
17 | cout << (X>Y) ? (L-X) : (L-Y) << endl;
| ~~~~~~^~~~~~~
|
s640618628 | p00499 | C++ | #! /usr/bin/env ruby
# coding: utf-8
L = gets.to_i
A = gets.to_i
B = gets.to_i
C = gets.to_i
D = gets.to_i
puts L - [(A + C - 1)/C.to_i, (B + D - 1)/D.to_i].max | a.cc:1:2: error: invalid preprocessing directive #!
1 | #! /usr/bin/env ruby
| ^
a.cc:2:3: error: invalid preprocessing directive #coding
2 | # coding: utf-8
| ^~~~~~
a.cc:3:1: error: 'L' does not name a type
3 | L = gets.to_i
| ^
|
s604816652 | p00499 | C++ | #include<stdio.h>
#include<algorithm>
using namespace std;
int main(){
int a,b,c,d,e;
scanf("%d%d%d%d%d",&a,&b,&c,&d,&e);
printf("%d\n",a-max((b+d-1)/d-(c+e-1)/e));
} | a.cc: In function 'int main()':
a.cc:7:28: error: no matching function for call to 'max(int)'
7 | printf("%d\n",a-max((b+d-1)/d-(c+e-1)/e));
| ~~~^~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:60,
from a.cc:2:
/usr/include/c++/14/bits... |
s338314527 | p00499 | C++ | #include <iostream>
#include <algroithm>
#include <cmath>
using namespace std;
int main()
{
int L, A, B, C, D;
cin >> L >> A >> B >> C >> D;
cout << L - max(ceil((double)A / C), ceil((double)B / D)) << endl;
return 0;
} | a.cc:2:10: fatal error: algroithm: No such file or directory
2 | #include <algroithm>
| ^~~~~~~~~~~
compilation terminated.
|
s481378074 | p00499 | C++ | a,b,c,d,e,*p=&a;main(){while(~scanf("%d",p++));printf("%.f\n",a-fmax(--b/d,--c/e)-1);} | a.cc:1:1: error: 'a' does not name a type
1 | a,b,c,d,e,*p=&a;main(){while(~scanf("%d",p++));printf("%.f\n",a-fmax(--b/d,--c/e)-1);}
| ^
a.cc:1:17: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
1 | a,b,c,d,e,*p=&a;main(){while(~scanf("%d",p++));printf("%.f\n",a-fmax(--b/d,--c... |
s345979264 | p00499 | C++ | #include<iostream>
using namespace std;
int main(){
int L,A,B,C,D,x,y;
cin >>L >>A >>B >>C >>D;
if(A%C==0)
x=A/C;
else
x=A/C+1;
if(B%D==0)
y=B/D;
else
y=B/D+1;
if(x<y)
x=y;
cout << L-x <<endl";
return 0;
} | a.cc:18:27: warning: missing terminating " character
18 | cout << L-x <<endl";
| ^
a.cc:18:27: error: missing terminating " character
18 | cout << L-x <<endl";
| ^~
a.cc: In function 'int main()':
a.cc:18:27: error: expected ';' befor... |
s414627022 | p00500 | Java | import java.util.*;
public class UniqueNumber {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int i,j,k,c = 0;
int[][] a;
a = new int[n][n];
for(i=0; i<n; i++){
a[0][i] = sc.nextInt();
a[1][i] = sc.nextInt();
a[2][i] = sc.nextInt();
}
for... | Main.java:2: error: class UniqueNumber is public, should be declared in a file named UniqueNumber.java
public class UniqueNumber {
^
1 error
|
s465602972 | p00500 | Java | import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Comparator;
import java.util.Deque;
import java.util.HashMap;
import java.util.InputMismatchException;
... | Main.java:22: error: incompatible types: int[][] cannot be converted to int[]
static int[] num=new int[201][3];
^
Main.java:28: error: incompatible types: int[] cannot be converted to int
for(int i=0;i<n;i++) num[i]=ir.toIntArray(3);
^
Main.java:32: error: array... |
s485233854 | p00500 | Java | public class Main {
public static void main(String[] args){
Scanner sc = new Scanner(System.in);
int N = sc.nextInt();
int i, k, cnt=0, searched, search;
int data[][] = new int[201][3];
int point[] = new int[201];
//????????¬?????????????????????????????????????????????
for(i = 1; i <= N; i++){
for(k... | Main.java:3: error: cannot find symbol
Scanner sc = new Scanner(System.in);
^
symbol: class Scanner
location: class Main
Main.java:3: error: cannot find symbol
Scanner sc = new Scanner(System.in);
^
symbol: class Scanner
location: class Main
2 errors
|
s663786630 | p00500 | Java | public class Main {
public static void main(String[] args){
Scanner sc = new Scanner(System.in);
int N = sc.nextInt();
int i, k, searched, search;
int data[][] = new int[201][3];
int point[] = new int[201];
//????????¬?????????????????????????????????????????????
for(i = 1; i <= N; i++){
for(k = 1; k... | Main.java:3: error: cannot find symbol
Scanner sc = new Scanner(System.in);
^
symbol: class Scanner
location: class Main
Main.java:3: error: cannot find symbol
Scanner sc = new Scanner(System.in);
^
symbol: class Scanner
location: class Main
2 errors
|
s112282678 | p00500 | Java | import java.util.Scanner;
public class B1 {
public static void main(String[] args){
Scanner sc = new Scanner(System.in);
int N = sc.nextInt();
int i, k, searched, search;
int data[][] = new int[201][3];
int point[] = new int[201];
//????????¬?????????????????????????????????????????????
for(i = 1; i <=... | Main.java:3: error: class B1 is public, should be declared in a file named B1.java
public class B1 {
^
1 error
|
s306982327 | p00500 | Java | import java.util.Scanner;
public class ex0 {
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
int[][] point=new int[200][10];
int[] point2=new int[200];
int n=sc.nextInt();
int s=0;
for(int i=1;i<=n;i++) point2[i]=0;
for(int i=1;i<=3;i++){
for(int j=1;j<=n;j++){
poin... | Main.java:2: error: class ex0 is public, should be declared in a file named ex0.java
public class ex0 {
^
1 error
|
s379943050 | p00500 | Java | import java.util.Scanner;
public class ex0 {
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
int[][] point=new int[200][10];
int[] point2=new int[200];
int n=sc.nextInt();
int s=0;
for(int i=1;i<=200;i++) point2[i]=0;
for(int i=1;i<=3;i++){
for(int j=1;j<=n;j++){
po... | Main.java:2: error: class ex0 is public, should be declared in a file named ex0.java
public class ex0 {
^
1 error
|
s691889612 | p00500 | Java | import java.util.Scanner;
public class???Main {
public static void main(String[] args) {
// TODO ?????????????????????????????????????????????
Scanner sc=new Scanner(System.in);
int n=sc.nextInt();
int[][] player=new int[3][n];
int[] point=new int[n];
for(int i=0;i<n;i++){
for(int j=0;j<3;j++){
pla... | Main.java:2: error: <identifier> expected
public class???Main {
^
1 error
|
s090973314 | p00500 | Java | import java.util.Scanner;
public class???Main {
public static void main(String[] args) {
// TODO ?????????????????????????????????????????????
Scanner sc=new Scanner(System.in);
int n=sc.nextInt();
int[][] player=new int[3][n];
int[] point=new int[n];
for(int i=0;i<n;i++){
for(int j=0;j<3;j++){
pla... | Main.java:2: error: <identifier> expected
public class???Main {
^
1 error
|
s293842578 | p00500 | Java | import java.util.Scanner;
public class Main {
void check(int a,int b,int n,int i) {
for(int k=1;k<=n;k++){
if(point[j][i]==point[k][i] && ) s+=1;
}
}
public static void main(String[] args) {
Scanner sc =new Scanner(System.in);
int[][] point=new int[300][10];
int[] score=new int[102];
for(int i... | Main.java:5: error: illegal start of expression
if(point[j][i]==point[k][i] && ) s+=1;
^
1 error
|
s800837917 | p00500 | Java | import java.util.Scanner;
public class Main {
public static void main(String[] args){
Scanner sc = new Scanner(System.in);
int N = sc.nextInt();
int card [][] = new int[N][3];
int score [] = new int[N];
int count [][] = new int[N][3];
for(int i = 0 ; i < N ; i++){
card[i][0] = sc.nextInt();
card[... | Main.java:30: error: reached end of file while parsing
}
^
1 error
|
s755793172 | p00500 | Java |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
// TODO ?????????????????????????????????????????????
Scanner sc = new Scanner(System.in);
//int i, k;
int n = sc.nextInt();
int[][] score = new int [n][3];
int[][] score1 = new int [n][3];
int[] sum = new int [5];
... | Main.java:13: error: cannot find symbol
for(i = 0; i < n; i++){
^
symbol: variable i
location: class Main
Main.java:13: error: cannot find symbol
for(i = 0; i < n; i++){
^
symbol: variable i
location: class Main
Main.java:13: error: cannot find symbol
for(i = 0; i < n; i++){
... |
s293476111 | p00500 | Java | import java.util.*;
public class AOJ0577{
public static void main(String[] args) {
Scanner sc=new Scanner(System.in);
int i,j,k,x,c;
int p=sc.nextInt();
int [][]ps =new int[p][3];
for(i=0;i<p;i++){
for(j=0;j<3;j++){
int s=sc.nextInt();
ps[i][j]=s;
}
}
int [][]sf = new int[p][3];
fo... | Main.java:2: error: class AOJ0577 is public, should be declared in a file named AOJ0577.java
public class AOJ0577{
^
1 error
|
s337610862 | p00500 | Java | import java.util.Scanner;
public class AOJ0577 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int N = sc.nextInt();
while(N < 2 || 200 < N){
System.out.println("2から200までの数を入力してください。");
N = sc.nextInt();
}
int[][] num = new int[N][3];
int[] point = new int[N];
int ... | Main.java:3: error: class AOJ0577 is public, should be declared in a file named AOJ0577.java
public class AOJ0577 {
^
1 error
|
s138115916 | p00500 | Java | package software_design;
import java.util.Scanner;
public class AOJ0577 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int[][] a = new int[3][n];
for(int i=0;i<n;i++) {
for(int j=0;j<3;j++) {
a[j][i] = sc.next... | Main.java:3: error: class AOJ0577 is public, should be declared in a file named AOJ0577.java
public class AOJ0577 {
^
1 error
|
s841819600 | p00500 | Java | import java.util.Scanner;
public class AOJ0577 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int[][] a = new int[3][n];
for(int i=0;i<n;i++) {
for(int j=0;j<3;j++) {
a[j][i] = sc.nextInt();
}
... | Main.java:2: error: class AOJ0577 is public, should be declared in a file named AOJ0577.java
public class AOJ0577 {
^
1 error
|
s633152549 | p00500 | C | #include<stdio.h>
n[3][101];
a[200][3]
int main(void){
int N,i,j;
for(i=0;i<N;i++){
for(j=0;j<3;j++){
int k=0;
scanf("%d",&k);
n[j][k]++;
a[i][j]=k;
}
}
for(i=0;i<N;i++){
int l=0;
for(j=0;j<3;j++){
if(n[j][a[i][j]]==1){l+=a[i][j];}
}
printf("%d\n",l);
}
return 0;
} | main.c:2:1: warning: data definition has no type or storage class
2 | n[3][101];
| ^
main.c:2:1: error: type defaults to 'int' in declaration of 'n' [-Wimplicit-int]
main.c:3:10: error: expected ';' before 'int'
3 | a[200][3]
| ^
| ;
4 | int main(void){
| ~~~ ... |
s547879907 | p00500 | C | #include <stdio.h>
int main() {
int i, j, n, flg;
int res[100][4] = {0};
scanf("%d", &n);
for( i = 0; i < n; i++ ) {
for( j = 0; j < 3; j++) {
scanf("%d", &res[i][j]);
}
}
for( i = 0; i < n; i++ ){
flg = 1;
for( j = 0; j < 3; j++ ) {
for ( k = 0; k < 3; k++) {
if( k != j ) {
if(res[i][j] =... | main.c: In function 'main':
main.c:15:31: error: 'k' undeclared (first use in this function)
15 | for ( k = 0; k < 3; k++) {
| ^
main.c:15:31: note: each undeclared identifier is reported only once for each function it appears in
|
s152663976 | p00500 | C | #include <stdio.h>
int main() {
int i, j, k, n, res, flg;
int score[200][3] = { 0 };
// 入力
scanf("%d", &n);
for ( i = 0; i < n; i++){
for ( j = 0; j < 3; j++) {
scanf("%d", &score[i][j]);
}
}
// 計算
for ( i = 0; i < n; i++) {
res = 0;
flg = 0;
for ( j = 0; j < 3; j++) {
for ( k = 0; k < n; k++) ... | main.c: In function 'main':
main.c:20:44: error: 'socre' undeclared (first use in this function); did you mean 'score'?
20 | if(socre[i][j] == score[k][j]) flg = 1;
| ^~~~~
| scor... |
s154652357 | p00500 | C | #include<stdio.h>
int main(){
int player,i,j,k,sum;
scanf("%d\n",&player);
int point[player][3];
int respoint[player][3]
for(j=0;j<player;j++){
scanf("%d %d %d\n",&point[j][0],&point[j][1],&point[j][2]);
}
for(j=0;j<player;j++){
for(i=0;i<3;i++){
for(k=0;k<player;k++){
if(point[j][i]==point[k][i] && j!=k)flag=1
}
if (f... | main.c: In function 'main':
main.c:7:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
7 | for(j=0;j<player;j++){
| ^~~
main.c:13:37: error: 'flag' undeclared (first use in this function)
13 | if(point[j][i]==point[k][i] && j!=k)flag=1
| ^~~~
... |
s914333938 | p00500 | C | #include<stdio.h>
int main(){
int player,i,j,k,sum;
scanf("%d\n",&player);
int point[player][3];
int respoint[player][3]
for(j=0;j<player;j++){
scanf("%d %d %d\n",&point[j][0],&point[j][1],&point[j][2]);
}
for(j=0;j<player;j++){
for(i=0;i<3;i++){
for(k=0;k<player;k++){
if(point[j][i]==point[k][i] && j!=k)flag=1
}
if (f... | main.c: In function 'main':
main.c:7:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
7 | for(j=0;j<player;j++){
| ^~~
main.c:13:37: error: 'flag' undeclared (first use in this function)
13 | if(point[j][i]==point[k][i] && j!=k)flag=1
| ^~~~
... |
s910774756 | p00500 | C | #include<stdio.h>
int main(){
int player,i,j,k,sum,flag;
scanf("%d\n",&player);
int point[player][3];
int respoint[player][3]
for(j=0;j<player;j++){
scanf("%d %d %d\n",&point[j][0],&point[j][1],&point[j][2]);
}
for(j=0;j<player;j++){
for(i=0;i<3;i++){
for(k=0;k<player;k++){
if(point[j][i]==point[k][i] && j!=k)flag=1
}
... | main.c: In function 'main':
main.c:7:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
7 | for(j=0;j<player;j++){
| ^~~
main.c:13:43: error: expected ';' before '}' token
13 | if(point[j][i]==point[k][i] && j!=k)flag=1
| ^
| ... |
s732109063 | p00500 | C | #include<stdio.h>
int main(){
int player,i,j,k,sum,flag;
scanf("%d\n",&player);
int point[player][3];
int respoint[player][3]
for(j=0;j<player;j++){
scanf("%d %d %d\n",&point[j][0],&point[j][1],&point[j][2]);
}
for(j=0;j<player;j++){
for(i=0;i<3;i++){
for(k=0;k<player;k++){
if(point[j][i]==point[k][i] && j!=k)flag=1;
}... | main.c: In function 'main':
main.c:7:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
7 | for(j=0;j<player;j++){
| ^~~
main.c:15:14: error: 'respoint' undeclared (first use in this function); did you mean 'point'?
15 | if (flag==0) respoint[j][i]=point[j][i]; else respoint[j][i]=0;
... |
s304296020 | p00500 | C | #include<stdio.h>
int main(){
int player,i,j,k,sum,flag;
scanf("%d\n",&player);
int point[player][3];
int respoint[player][3]
for(j=0;j<player;j++){
scanf("%d %d %d\n",&point[j][0],&point[j][1],&point[j][2]);
}
for(j=0;j<player;j++){
for(i=0;i<3;i++){
for(k=0;k<player;k++){
if(point[j][i]==point[k][i] && j!=k)flag=1;
}... | main.c: In function 'main':
main.c:7:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
7 | for(j=0;j<player;j++){
| ^~~
main.c:15:14: error: 'respoint' undeclared (first use in this function); did you mean 'point'?
15 | if (flag==0) respoint[j][i]=point[j][i]; else respoint[j][i]=0;
... |
s513759603 | p00500 | C | #include<stdio.h>
int main(){
int player,i,j,k,sum,flag=0;
scanf("%d\n",&player);
int point[player][3];
int respoint[player][3]
for(j=0;j<player;j++){
scanf("%d %d %d\n",&point[j][0],&point[j][1],&point[j][2]);
}
for(j=0;j<player;j++){
for(i=0;i<3;i++){
for(k=0;k<player;k++){
if(point[j][i]==point[k][i] && j!=k)flag=1;... | main.c: In function 'main':
main.c:7:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
7 | for(j=0;j<player;j++){
| ^~~
main.c:15:14: error: 'respoint' undeclared (first use in this function); did you mean 'point'?
15 | if (flag==0) respoint[j][i]=point[j][i]; else respoint[j][i]=0;
... |
s142149162 | p00500 | C | #include<stdio.h>
int main(){
int player,i,j,k,sum,flag=0;
scanf("%d\n",&player);
int point[player][3];
int respoint[player][3]
for(j=0;j<player;j++){
scanf("%d %d %d\n",&point[j][0],&point[j][1],&point[j][2]);
}
for(j=0;j<player;j++){
for(i=0;i<3;i++){
for(k=0;k<player;k++){
if(point[j][i]==point[k][i] && j!=k)flag=1;... | main.c: In function 'main':
main.c:7:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
7 | for(j=0;j<player;j++){
| ^~~
main.c:15:14: error: 'respoint' undeclared (first use in this function); did you mean 'point'?
15 | if (flag==0) respoint[j][i]=point[j][i];else respoint[j][i]=0;
... |
s686831708 | p00500 | C | /*??°???????????????(Unique number)*/
#include <stdio.h>
int main(){
int i, k, l, x, N;
int data[200][3];
int sum[200];
scanf("%d", &N);
for (i = 0; i < N; i++) {
for (k = 0; k < 3; k++) {
scanf("%d", &data[i][k]);
}
}
for (i = 0; i < N; i++) {
for (k = 0; k < 3; k++) {
for (l = 0; l ... | main.c: In function 'main':
main.c:22:17: error: assignment to expression with array type
22 | data[k] += 0;
| ^~
main.c:24:17: error: assignment to expression with array type
24 | data[k] += data[i][k];
| ^~
|
s898426471 | p00500 | C | #include <stdio.h>
int main()
{
int n, n[101][3], sum[101];
int i, j, k;
scanf("%d"&n);
for (i = 0;i < n;i++) {
scanf("%d%d%d", &n[i][0], &n[i][1], &n[i][2]);
}
for (k = 0;k < 3;k++) {
for (i = 0;i < n;i++) {
for (j = 0;j < n;j++) {
if (n[i][k] == n[j][k]) { sum[i] += 0;break; };
else???sum[i] +=... | main.c: In function 'main':
main.c:5:16: error: conflicting types for 'n'; have 'int[101][3]'
5 | int n, n[101][3], sum[101];
| ^
main.c:5:13: note: previous declaration of 'n' with type 'int'
5 | int n, n[101][3], sum[101];
| ^
main.c:16:33: error: 'else' ... |
s243904084 | p00500 | C | include <stdio.h>
int main()
{
int n, N[201][3], sum[201] = { 0 }, cnt[201][3];
int i, j, k;
scanf("%d", &n);
for (i = 0;i < n;i++) {
scanf("%d%d%d", &N[i][0], &N[i][1], &N[i][2]);
cnt[i][0] = 0;cnt[i][2] = 0;cnt[i][1]=0;
}
for(k=0;k<3;k++){
for (i = 0;i < n;i++) {
for (j = 0;j < n;j++) {
if (N[i][... | main.c:1:9: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
1 | include <stdio.h>
| ^
|
s448612058 | p00500 | C | #include <stdio.h>
int main() {
int N;
int i,j,k;
int a[100][3];
int d[100][3];
scanf("%d",&N);
for(i=0;i<N;++i){
scanf("%d%d%d",&a[i][0],&a[i][1],&a[i][2]);
d[i][0]=a[i][0]; d[i][1]=a[i][1]; d[i][2]=a[i][2];
}
for(i=0;i<3;++i){
for(j=0;j<N;++j){
for(k=0;k<N;++k){
if(j==k)continue;... | main.c: In function 'main':
main.c:23:23: error: stray '\343' in program
23 | for(i=0;i<N;i++)<U+30C6><U+300D><U+30C4>??rintf("%d\n",d[i][0]+d[i][1]+d[i][2]);
| ^~~~~~~~
main.c:23:21: error: '\U000030c6' undeclared (first use in this function)
23 | for(i=0;i<N;i++)テ」ツ??ri... |
s036275181 | p00500 | C | include<stdio.h>
int main(){
int i,j,k,n,c[200][3],a;
for(i=0;i<n;i++){
for(j=0;j<=2;i++){
cin>>c[i][j];
for(j=0;j<=2;j++){
for(i=0;i<n;i++){
a=0;
for(k=0;k<=n;k++){
if(c[i][j]==c[k][j]){
c[k][j]=0;
a=1;
}
}
if(a==1){
c[i][j]=0;
}
}
for(i=0;i<n;i++){
printf("%d",c[i][0]... | main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
1 | include<stdio.h>
| ^
|
s458320233 | p00500 | C | include<stdio.h>
int main(){
int i,j,k,n,c[200][3],a;
for(i=0;i<n;i++){
for(j=0;j<=2;i++){
cin>>c[i][j];
for(j=0;j<=2;j++){
for(i=0;i<n;i++){
a=0;
for(k=0;k<=n;k++){
if(c[i][j]==c[k][j]){
c[k][j]=0;
a=1;
}
}
if(a==1){
c[i][j]=0;
}
}
for(i=0;i<n;i++){
printf("%d",c[i][0]... | main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
1 | include<stdio.h>
| ^
|
s975329372 | p00500 | C | #include<stdio.h>
int main(){
int i,j,k,n,c[200][3],a;
for(i=0;i<n;i++){
for(j=0;j<=2;i++){
cin>>c[i][j];
for(j=0;j<=2;j++){
for(i=0;i<n;i++){
a=0;
for(k=0;k<=n;k++){
if(c[i][j]==c[k][j]){
c[k][j]=0;
a=1;
}
}
if(a==1){
c[i][j]=0;
}
}
for(i=0;i<n;i++){
printf("%d",c[i][0... | main.c: In function 'main':
main.c:6:25: error: 'cin' undeclared (first use in this function)
6 | cin>>c[i][j];
| ^~~
main.c:6:25: note: each undeclared identifier is reported only once for each function it appears in
main.c:24:1: error: expected declaration or ... |
s462495777 | p00500 | C | #include<stdio.h>
int main(){
int i,j,k,n,c[200][3],a;
for(i=0;i<n;i++){
for(j=0;j<=2;i++){
scanf("%d",c[i][j]);
for(j=0;j<=2;j++){
for(i=0;i<n;i++){
a=0;
for(k=0;k<=n;k++){
if(c[i][j]==c[k][j]){
c[k][j]=0;
a=1;
}
}
if(a==1){
c[i][j]=0;
}
}
for(i=0;i<n;i++){
printf("%d"... | main.c: In function 'main':
main.c:24:1: error: expected declaration or statement at end of input
24 | }
| ^
main.c:24:1: error: expected declaration or statement at end of input
main.c:24:1: error: expected declaration or statement at end of input
|
s485576075 | p00500 | C | #include<stdio.h>
int main(){
int i,j,k,n,c[200][3],a;
for(i=0;i<n;i++){
for(j=0;j<=2;i++){
scanf("%d",c[i][j]);
for(j=0;j<=2;j++){
for(i=0;i<n;i++){
a=0;
for(k=0;k<=n;k++){
if(c[i][j]==c[k][j]){
c[k][j]=0;
a=1;
}
}
if(a==1){
c[i][j]=0;
}
}
}
for(i=0;i<n;i++){
printf... | main.c: In function 'main':
main.c:25:1: error: expected declaration or statement at end of input
25 | }
| ^
main.c:25:1: error: expected declaration or statement at end of input
|
s127752362 | p00500 | C | #include <stdio.h>
int main(){
int N,k,i,g,j;
scanf("%d",&N);
int a[3][1000],n[1000]={0};
for(i=0;i<N;i++){
?????? scanf("%d %d %d\n",&a[0][i],&a[1][i],&a[2][i]);
}
for(i=0;i<N;i++){
?????????????? g=0;
for(j=0;j<3;j++){
?????????????? for(k=i+1;k<N+1;k++){
?????????????????????? if(a[j][i]==a[j][k])g=1;}
???????????... | main.c: In function 'main':
main.c:8:1: error: expected expression before '?' token
8 | ?????? scanf("%d %d %d\n",&a[0][i],&a[1][i],&a[2][i]);
| ^
main.c:12:1: error: expected expression before '?' token
12 | ?????????????? g=0;
| ^
main.c:14:1: error: expected expression before '?' token
14 | ???... |
s638354750 | p00500 | C | #include <stdio.h>
int main(){
int N,k,i,g,j;
scanf("%d",&N);
int a[1000][3],n[1000]={0};
for(i=0;i<N;i++){
?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
}
for(i=0;i<N;i++){
?????????????? g=0;
for(j=0;j<3;j++){
?????????????? for(k=i+1;k<N+1;k++){
?????????????????????? if(a[i][j]==a[k][j])g=1;}
???????????... | main.c: In function 'main':
main.c:8:1: error: expected expression before '?' token
8 | ?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
| ^
main.c:12:1: error: expected expression before '?' token
12 | ?????????????? g=0;
| ^
main.c:14:1: error: expected expression before '?' token
14 | ???... |
s431111310 | p00500 | C | #include <stdio.h>
int main(){
int N,k,i,g,j;
scanf("%d",&N);
int a[1000][3],n[1000]={0};
for(i=0;i<N;i++){
?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
}
for(i=0;i<N;i++){
?????????????? g=0;
for(j=0;j<3;j++){
?????????????? for(k=i+1;k<N+1;k++){
?????????????????????? if(a[i][j]==a[k][j])g=1;}
???????????... | main.c: In function 'main':
main.c:8:1: error: expected expression before '?' token
8 | ?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
| ^
main.c:12:1: error: expected expression before '?' token
12 | ?????????????? g=0;
| ^
main.c:14:1: error: expected expression before '?' token
14 | ???... |
s372941116 | p00500 | C | #include <stdio.h>
int main(){
int N,k,i,g,j;
scanf("%d",&N);
int a[1000][3],n[1000]={0};
for(i=0;i<N;i++){
?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
}
for(i=0;i<N;i++){
?????????????? g=0;
for(j=0;j<3;j++){
?????????????? for(k=i;k<N;k++){
?????????????????????? if(i!=k&&a[i][j]==a[k][j])g=1;}
?????????... | main.c: In function 'main':
main.c:8:1: error: expected expression before '?' token
8 | ?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
| ^
main.c:12:1: error: expected expression before '?' token
12 | ?????????????? g=0;
| ^
main.c:14:1: error: expected expression before '?' token
14 | ???... |
s196211899 | p00500 | C | #include <stdio.h>
int main(){
int N,k,i,g,j,a[1000][3],n[1000]={0};
scanf("%d",&N);
for(i=0;i<N;i++){
?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
}
for(i=0;i<N;i++){
?????????????? g=0;
for(j=0;j<3;j++){
?????????????? for(k=i;k<N;k++){
?????????????????????? if(i!=k&&a[i][j]==a[k][j])g=1;}
????????????... | main.c: In function 'main':
main.c:9:1: error: expected expression before '?' token
9 | ?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
| ^
main.c:13:1: error: expected expression before '?' token
13 | ?????????????? g=0;
| ^
main.c:15:1: error: expected expression before '?' token
15 | ???... |
s405755390 | p00500 | C | #include <stdio.h>
int main(){
int N,k,i,g,j,a[1000][3],n[1000]={0};
scanf("%d",&N);
for(i=0;i<N;i++){
?????? scanf("%d %d %d/n",&a[i][0],&a[i][1],&a[i][2]);
}
for(i=0;i<N;i++){
?????????????? g=0;
for(j=0;j<3;j++){
?????????????? for(k=i;k<N;k++){
?????????????????????? if(i!=k&&a[i][j]==a[k][j])g=1;}
????????????... | main.c: In function 'main':
main.c:9:1: error: expected expression before '?' token
9 | ?????? scanf("%d %d %d/n",&a[i][0],&a[i][1],&a[i][2]);
| ^
main.c:13:1: error: expected expression before '?' token
13 | ?????????????? g=0;
| ^
main.c:15:1: error: expected expression before '?' token
15 | ???... |
s182961783 | p00500 | C | #include <stdio.h>
int main(){
int N,k,i,g,j,a[1000][3],n[1000]={0};
scanf("%d",&N);
for(i=0;i<N;i++){
?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
}
for(i=0;i<N;i++){
?????????????? g=0;
for(j=0;j<3;j++){
?????????????? for(k=i;k<N;k++){
?????????????????????? if(i!=k&&a[i][j]==a[k][j])g=1;}
????????????... | main.c: In function 'main':
main.c:9:1: error: expected expression before '?' token
9 | ?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
| ^
main.c:13:1: error: expected expression before '?' token
13 | ?????????????? g=0;
| ^
main.c:15:1: error: expected expression before '?' token
15 | ???... |
s065810487 | p00500 | C | #include <stdio.h>
int main(){
int N,k,i,g,j,a[1000][3],n[1000]={0};
scanf("%d",&N);
for(i=0;i<N;i++){
?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
}
for(i=0;i<N;i++){
??????????????
for(j=0;j<3;j++){
g=0;
?????????????? for(k=i;k<N;k++){
?????????????????????? if(i!=k&&a[i][j]==a[k][j])g=1;}
???????????... | main.c: In function 'main':
main.c:9:1: error: expected expression before '?' token
9 | ?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
| ^
main.c:13:1: error: expected expression before '?' token
13 | ??????????????
| ^
main.c:26:1: error: expected expression before '?' token
26 | ?????? p... |
s862362348 | p00500 | C | #include <stdio.h>
int main(){
int n,k,i,g,j,a[1000][3],s[1000]={0};
scanf("%d",&n);
for(i=0;i<n;i++){
?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
}
for(i=0;i<n;i++){
??????????????
for(j=0;j<3;j++){
g=0;
?????????????? for(k=i;k<n;k++){
?????????????????????? if(i!=k&&a[i][j]==a[k][j])g=1;}
???????????... | main.c: In function 'main':
main.c:9:1: error: expected expression before '?' token
9 | ?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
| ^
main.c:13:1: error: expected expression before '?' token
13 | ??????????????
| ^
main.c:26:1: error: expected expression before '?' token
26 | ?????? p... |
s927387857 | p00500 | C | #include <stdio.h>
int main(){
int n,k,i,g,j,a[1000][3],s[1000]={0};
scanf("%d",&n);
for(i=0;i<n;i++){
?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
}
for(i=0;i<n;i++){
??????????????
for(j=0;j<3;j++){
g=0;
?????????????? for(k=i;k<n;k++){
?????????????????????? if(i!=k&&a[i][j]==a[k][j])g=1;}
???????????... | main.c: In function 'main':
main.c:9:1: error: expected expression before '?' token
9 | ?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);
| ^
main.c:13:1: error: expected expression before '?' token
13 | ??????????????
| ^
main.c:26:1: error: expected expression before '?' token
26 | ?????? p... |
s417250334 | p00500 | C | #include <stdio.h>
int main(){
int n,k,i,g,j,a[1000][3],s[1000]={0};
scanf("%d",&n);
for(i=0;i<n;i++){
?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);}
for(i=0;i<n;i++){
??????????????
for(j=0;j<3;j++){
g=0;
?????????????? for(k=0;k<n;k++){
?????????????????????? if(i!=k&&a[i][j]==a[k][j])g=1;}
????????????... | main.c: In function 'main':
main.c:9:1: error: expected expression before '?' token
9 | ?????? scanf("%d %d %d\n",&a[i][0],&a[i][1],&a[i][2]);}
| ^
main.c:12:1: error: expected expression before '?' token
12 | ??????????????
| ^
main.c:22:1: error: expected expression before '?' token
22 | ?????? ... |
s809367561 | p00500 | C | include<stdio.h>
#include<math.h>
int main(void)
{
int N;//人数
int i;//loop
int j;//loop
int k;//loop
int I[101][4];//NumberCheck
scanf ("%d",&N);
int P[N+1][4];//point
int Pv[N+1];//getPoint
for (j=1;j<=3;j++){
for (i=1;i<=100 ; i++){
I[i][j]=0;
}
}
for (i=1; i<=N;i++){
// for (j=0;... | main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
1 | include<stdio.h>
| ^
main.c: In function 'main':
main.c:11:3: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
11 | scanf ("%d",&N);
| ^~~~~
main.c:3:1: note: include '... |
s767496239 | p00500 | C++ | #include<iostream>
#include<cstdio>
#include<algorithm>
int main(void)
{
int N=0;
int out1[101]={0};int out2[101]={0};int out3[101]={0};
int a[660]={0};int a1[660]={0};int a2[660]={0};
int all[220]={0};
scanf("%d",&N);
for(int i=1;i<=N;i++){
scanf("%d %d %d",a[i],a1[i],a2[i]);
if(out1[a[i]]<0){out1=-2;}
els... | a.cc: In function 'int main()':
a.cc:13:38: error: incompatible types in assignment of 'int' to 'int [101]'
13 | if(out1[a[i]]<0){out1=-2;}
| ~~~~^~~
a.cc:15:39: error: incompatible types in assignment of 'int' to 'int [101]'
15 | if(out2[a1[i... |
s787905937 | p00500 | C++ | #include<iostream>
#include<cstdio>
#include<algorithm>
int main(void)
{
int N=0;
int out1[101]={0};int out2[101]={0};int out3[101]={0};
int a[660]={0};int a1[660]={0};int a2[660]={0};
int all[220]={0};
scanf("%d",&N);
for(int i=1;i<=N;i++){
scanf("%d %d %d",&a[i],&a1[i],&a2[i]);
if(out1[a[i]]<0){out1=-2;}
... | a.cc: In function 'int main()':
a.cc:13:38: error: incompatible types in assignment of 'int' to 'int [101]'
13 | if(out1[a[i]]<0){out1=-2;}
| ~~~~^~~
a.cc:15:39: error: incompatible types in assignment of 'int' to 'int [101]'
15 | if(out2[a1[i... |
s247014507 | p00500 | C++ | #include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int main() {
int n;
cin >> n;
vector<vector<int>> v(3, vector<int>(n));
for (int i = 0; i < n; i++)
for (int j = 0; j < 3; j++)
cin >> v[j][i];
for (int i = 0; i < n; i++) {
int ans = 0;
... | a.cc: In function 'int main()':
a.cc:16:28: error: '__gnu_cxx::__alloc_traits<std::allocator<std::vector<int> >, std::vector<int> >::value_type' {aka 'class std::vector<int>'} has no member named 'count'
16 | if (count(v[j].count(), v[j].end(), v[j][i]) == 1)
| ^~~~~
|
s695896918 | p00500 | C++ | #include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int main() {
int n;
cin >> n;
vector<vector<int> > v(3, vector<int>(n));
for (int i = 0; i < n; i++)
for (int j = 0; j < 3; j++)
cin >> v[j][i];
for (int i = 0; i < n; i++) {
int ans = 0;
... | a.cc: In function 'int main()':
a.cc:16:28: error: '__gnu_cxx::__alloc_traits<std::allocator<std::vector<int> >, std::vector<int> >::value_type' {aka 'class std::vector<int>'} has no member named 'count'
16 | if (count(v[j].count(), v[j].end(), v[j][i]) == 1)
| ^~~~~
|
s794608124 | p00500 | C++ | #include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
#rep(i,n) for(int i=0;i<n;i++)
#all(co)co.begin(),co.end()
int main()
{
int n; cin >> n;
vector<vector<int>> table(3, vector<int>(n));
vector<int> score(n);
rep(i,n)rep(j,3)cin>>table[j][i];
rep(j,3)rep(i,n)
{
if(count(all(t... | a.cc:5:2: error: invalid preprocessing directive #rep
5 | #rep(i,n) for(int i=0;i<n;i++)
| ^~~
a.cc:6:2: error: invalid preprocessing directive #all
6 | #all(co)co.begin(),co.end()
| ^~~
a.cc: In function 'int main()':
a.cc:12:7: error: 'i' was not declared in this scope
12 | rep(i,n)rep(j,3)... |
s802254038 | p00500 | C++ | #include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
#define rep(i,n) for(int i=0;i<n;i++)
#define all(co)co.begin(),co.end()
int main()
{
int n; cin >> n;
vector<vector<int>> table(3, vector<int>(n));
vector<int> score(n);
rep(i,n)rep(j,3)cin>>table[j][i];
rep(j,3)rep(i,n)
{
... | a.cc: In function 'int main()':
a.cc:17:15: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type' {aka 'int'})
17 | rep(i,n)cout>>score[i]>>endl;
a.cc:17:15: note: candidate: 'operator>>(int, __gnu_c... |
s081114475 | p00500 | C++ | #include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
#define rep(i,n) for(int i=0;i<n;i++)
#define all(co)co.begin(),co.end()
int main()
{
int n; cin >> n;
vector<vector<int>> table(3, vector<int>(n));
vector<int> score(n);
rep(i,n)rep(j,3)cin>>table[j][i];
rep(j,3)rep(i,n)
{
... | a.cc: In function 'int main()':
a.cc:17:15: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type' {aka 'int'})
17 | rep(i,n)cout>>score[i]>>endl;
a.cc:17:15: note: candidate: 'operator>>(int, __gnu_c... |
s751796626 | p00500 | C++ | a | a.cc:1:1: error: 'a' does not name a type
1 | a
| ^
|
s046374299 | p00500 | C++ | #include<stdio.h>
int zisaku(int data[][3], int N, int i, int k, int a){
int j, cnt = 0, result = 0;
for(j = 1; j <= N; j++){
if(i == j)continue;
if(a == data[j][k])cnt += 1;
}
if(cnt == 0)result += a;
return result;
}
int main(){
int N, i, k, j, l, a;
scanf("%d", &N);
int data[200][3];
for(i = 1; i <= N... | a.cc: In function 'int main()':
a.cc:25:55: error: too few arguments to function 'int zisaku(int (*)[3], int, int, int, int)'
25 | data[i][0] += zisaku(data, N, i, k);
| ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~
a.cc:3:9: n... |
s259662757 | p00500 | C++ | #include<stdio.h>
int zisaku(int data[][], int N, int i, int k, int a){
int j, cnt = 0, result = 0;
for(j = 1; j <= N; j++){
if(i == j)continue;
if(a == data[j][k])cnt += 1;
}
if(cnt == 0)result += a;
return result;
}
int main(){
int N, i, k, j, l, a;
scanf("%d", &N);
int data[200][3];
for(i = 1; i <= N;... | a.cc:3:25: error: declaration of 'data' as multidimensional array must have bounds for all dimensions except the first
3 | int zisaku(int data[][], int N, int i, int k, int a){
| ^~~~
a.cc:3:33: error: expected ')' before ',' token
3 | ... |
s029905636 | p00500 | C++ | int main(){
int N, i, k, cnt = 0, l, a, data[200][3];
scanf("%d", &N);
for(i = 1; i <= N; i++){
for(k = 1; k <= 3; k++){
scanf("%d", &data[i][k]);
}
}
for(k = 1; k <= 3; k++){
for(i = 1; i <= N; i++){
a = data[i][k];
for(l = 1; l <= N; l++){
if(i == l)continue;
if(a == data[l][k]){
cnt ... | a.cc: In function 'int main()':
a.cc:3:9: error: 'scanf' was not declared in this scope
3 | scanf("%d", &N);
| ^~~~~
a.cc:23:17: error: 'printf' was not declared in this scope
23 | printf("%d\n", data[i][0]);
| ^~~~~~
a.cc:1:1: note: 'printf' is de... |
s171786791 | p00500 | C++ | int main(){
int N, i, k, cnt = 0, l, a, data[200][3];
scanf("%d\n", &N);
for(i = 1; i <= N; i++){
for(k = 1; k <= 3; k++){
scanf("%d", &data[i][k]);
}
}
for(k = 1; k <= 3; k++){
for(i = 1; i <= N; i++){
a = data[i][k];
for(l = 1; l <= N; l++){
if(i == l)continue;
if(a == data[l][k]){
cn... | a.cc: In function 'int main()':
a.cc:3:9: error: 'scanf' was not declared in this scope
3 | scanf("%d\n", &N);
| ^~~~~
a.cc:23:17: error: 'printf' was not declared in this scope
23 | printf("%d\n", data[i][0]);
| ^~~~~~
a.cc:1:1: note: 'printf' is de... |
s867096198 | p00500 | C++ | int main(){
int N, i, k, cnt = 0, l, a, data[200][3];
scanf("%d\n", &N);
for(i = 1; i <= N; i++){
for(k = 1; k <= 3; k++){
scanf("%d", data[i][k]);
}
}
for(k = 1; k <= 3; k++){
for(i = 1; i <= N; i++){
a = data[i][k];
for(l = 1; l <= N; l++){
if(i == l)continue;
if(a == data[l][k]){
cnt... | a.cc: In function 'int main()':
a.cc:3:9: error: 'scanf' was not declared in this scope
3 | scanf("%d\n", &N);
| ^~~~~
a.cc:23:17: error: 'printf' was not declared in this scope
23 | printf("%d\n", data[i][0]);
| ^~~~~~
a.cc:1:1: note: 'printf' is de... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.