submission_id stringlengths 10 10 | problem_id stringlengths 6 6 | language stringclasses 3
values | code stringlengths 1 522k | compiler_output stringlengths 43 10.2k |
|---|---|---|---|---|
s961152384 | p03723 | C++ | #include <bits/stdc++.h>
#define ALL(v) v.begin(), v.end()
#define rep(i, n) for(int i = 0; i < (int)(n); i++)
using namespace std;
typedef long long ll;
int main() {
int a,b,c; cin>>a>>b>>c;
if(a&2==1||b%2==1||c%2==1){cout<<0<endl;
return 0;}
if(a==b&&b==c){cout<<-1<<endl;
return 0... | a.cc: In function 'int main()':
a.cc:9:37: error: no match for 'operator<' (operand types are 'std::basic_ostream<char>' and '<unresolved overloaded function type>')
9 | if(a&2==1||b%2==1||c%2==1){cout<<0<endl;
| ~~~~~~~^~~~~
In file included from /usr/include/c++/14/regex:68,
... |
s573638278 | p03723 | C++ | #include<bits/stdc++.h>
#define rep(i,n) for(int i=0, i##_len=(n); i<i##_len; ++i)
#define all(x) (x).begin(),(x).end()
typedef long long ll;
using namespace std;
#define sz(x) ((int)(x).size())
#define ZERO(a) memset(a,0,sizeof(a))
#include<bits/stdc++.h>
#define rep(i,n) for(int i=0, i##_len=(n); i<i##_len; ++i)
#def... | a.cc:35:17: error: extended character is not valid in an identifier
35 | if(A == B && A == C){
| ^
a.cc: In function 'int main()':
a.cc:35:17: error: 'B\U00003000' was not declared in this scope
35 | if(A == B && A == C){
| ^~~
|
s359769555 | p03723 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
int A,B,C;
cin>>A>>B>>C;
int it;
while(A%2==0&&B%2==0&&C%2==0){
int a=A/2,b=B/2,c=C/2;
B=a+c;
C=a+b;
A=b+c;
it++;
if(it>1000000){
cout<<-1<<endl;
return 0;
}`
}
cout<<it<<endl;
}
| a.cc:18:6: error: stray '`' in program
18 | }`
| ^
|
s765158217 | p03723 | C++ | #include <bits/stdc++.h>
using namespace std;
int main(){
long long int A,B,C;
cin >> A >> B >> C;
long long int D=max(abs(A-B),max(abs(B-C),abs(C-A)));
if (D==0)cout << -1 <<endl;
int count=0;
else {
if (A%2==1 || B%2==1 || C%2==1)cout << count <<endl;
else {
count++;
long long int D,E,F;
... | a.cc: In function 'int main()':
a.cc:9:3: error: 'else' without a previous 'if'
9 | else {
| ^~~~
|
s550199015 | p03723 | C++ | #include<bits/stdc++.h>
using namespace std;
int main()
{
double a,b,c;
int r=0;
double arr[3];
int p=-1;
double t1,t2,t3;
cin>>a>>b>>c;
if(a==b&&a==c&&b==c)
{
cout<<p<<endl;
}
else if(a%2==1||b%2==1||c%2==1)
{
cout<<p<<endl;
}
else
{
arr... | a.cc: In function 'int main()':
a.cc:18:14: error: invalid operands of types 'double' and 'int' to binary 'operator%'
18 | else if(a%2==1||b%2==1||c%2==1)
| ~^~
| | |
| | int
| double
a.cc:18:22: error: invalid operands of types 'double' and... |
s216369432 | p03723 | C++ | #include<bits/stdc++.h>
using namespace std;
int main()
{
double a,b,c;
int r=0;
int arr[3];
int p=-1;
int t1,t2,t3;
cin>>a>>b>>c;
if(a==b&&a==c&&b==c)
{
cout<<p<<endl;
}
else if(a%2==1||b%2==1||c%2==1)
{
cout<<p<<endl;
}
else
{
arr[0]=a;... | a.cc: In function 'int main()':
a.cc:18:14: error: invalid operands of types 'double' and 'int' to binary 'operator%'
18 | else if(a%2==1||b%2==1||c%2==1)
| ~^~
| | |
| | int
| double
a.cc:18:22: error: invalid operands of types 'double' and... |
s444479794 | p03723 | C++ | #include<bits/stdc++.h>
using namespace std;
using ll = long long;
#define MM 1000000000;
#define mod MM + 7;
#define INF (ll)1e18
#define pi acos(-1.0)
#define MAX 100005
#define NIL -1
int main(){
ll a, b, c; cin >> a >> b >> c;
ll ans;
for(int i = 0; i < 30; i++){
if(a == b && b == c){
... | a.cc: In function 'int main()':
a.cc:20:26: error: 'u' was not declared in this scope
20 | ll s = a, t = b; u = c;
| ^
|
s746364858 | p03723 | C++ | #include<bits/stdc++.h>
using namespace std;
using ll = long long;
#define MM = 1000000000;
#define mod = MM + 7;
#define INF (ll)1e18
#define pi acos(-1.0)
#define MAX 10000000005
#define NIL -1
int main(){
ll a, b, c; cin >> a >> b >> c;
ll s = a, t = b, u = c;
ll ans = 0;
for(ll i = 0;; i++){
... | a.cc: In function 'int main()':
a.cc:25:2: error: expected '}' at end of input
25 | }
| ^
a.cc:10:11: note: to match this '{'
10 | int main(){
| ^
|
s563287107 | p03723 | C++ | #include<bits/stdc++.h>
using namespace std;
using ll = long long;
#define MM = 1000000000;
#define mod = MM + 7;
#define INF (ll)1e18
#define pi acos(-1.0)
#define MAX 10000000005
#define NIL -1
int main(){
ll a, b, c; cin >> a >> b >> c;
ll s = a, t = b, u = c;
ll ans = 0;
for(ll i = 0;; i++){
... | a.cc: In function 'int main()':
a.cc:18:19: error: expected primary-expression before '||' token
18 | if(a%2==! || b%2== ! || c%2==1) ans = i;
| ^~
a.cc:18:30: error: expected primary-expression before '||' token
18 | if(a%2==! || b%2== ! || c%2==1) ans = i;
| ... |
s303734391 | p03723 | C++ | a, b, c = [int(x) for x in input().strip().split()]
def f(a, b, c, count):
if a % 2 == 1 and b % 2 == 1 and c % 2 == 1:
count += 1
return f(a/2+b/2, c/2+b/2, a/2+c/2, count)
elif a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
count += 1
return f(a/2+b/2, c/2+b/2, a/2+c/2, count)
... | a.cc:1:1: error: 'a' does not name a type
1 | a, b, c = [int(x) for x in input().strip().split()]
| ^
|
s340375983 | p03723 | C++ | #include<iostream>
using namespace std;
int main(){
long A,B,C;
cin>>A>>B>>C;
int ans=0;
if(A%2==!||B%2==1||C%2==1){
cout<<0<<endl;
return 0;
}
if(A==B&&B==C){
cout<<-1<<endl;
return 0;
}
else{
bool ccc=true;
while(ccc){
... | a.cc: In function 'int main()':
a.cc:13:14: error: expected primary-expression before '||' token
13 | if(A%2==!||B%2==1||C%2==1){
| ^~
|
s535274226 | p03723 | Java | import java.util.Arrays;
import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Scanner;
import java.util.Set;
public class Main1 {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int[] P = new int[3];
int i = 0;
while(i < 3) {
P[i] ... | Main.java:8: error: class Main1 is public, should be declared in a file named Main1.java
public class Main1 {
^
1 error
|
s719803668 | p03723 | Java | import java.util.Arrays;
import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Scanner;
import java.util.Set;
public class A_Cookie {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int[] P = new int[3];
int i = 0;
while(i < 3) {
P[... | Main.java:8: error: class A_Cookie is public, should be declared in a file named A_Cookie.java
public class A_Cookie {
^
1 error
|
s272566123 | p03723 | Java | import java.util.Arrays;
import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Scanner;
import java.util.Set;
public class A_Cookie {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int[] P = new int[3];
int i = 0;
while(i < 3) {
P[... | Main.java:8: error: class A_Cookie is public, should be declared in a file named A_Cookie.java
public class A_Cookie {
^
1 error
|
s568331957 | p03723 | Java | import java.io.BufferedReader;
import java.io.InputStreamReader;
public class Main {
public static void main(String[] args)throws Exception {
BufferedReader br = new BufferedReader ( new InputStreamReader(System.in));
String [] input = br.readLine().split(" ");
int A = Integer.parseInt(input[0]);
int B = Int... | Main.java:42: error: reached end of file while parsing
}
^
1 error
|
s367200005 | p03723 | C++ | #include <iostream>
#include<string>
using namespace std;
int main() {
long long a, b,c;
int iwa = 0;
cin >> a >> b>>c;
for (;;) {
if (a % 2 != 0 || b % 2 != 0 || c % 2 != 0) { cout << iwa << endl; break; }
else if (a == b && b == c) { cout << -1 << endl; break; }
a = b / 2 + c / 2;
b = a / 2 + c / 2;
c =... | a.cc: In function 'int main()':
a.cc:15:14: error: expected '}' at end of input
15 | }
| ^
a.cc:4:12: note: to match this '{'
4 | int main() {
| ^
|
s811224828 | p03723 | C++ | #include <iostream>
#include <stdio.h>
#include <algorithm>
//#include <string>
//#include <math.h>
//#include <vector>
using namespace std;
int main() {
int a, b, c;
long int a0, b0, c0;
long int counter=0;
cin >> a0 >> b0 >> c0;
while(a0%2==0 && b0%2==0 && c0%2==0){
counter++;
a = b0/2+c0/2... | a.cc:34:1: error: extended character is not valid in an identifier
34 |
| ^
a.cc:34:1: error: extended character is not valid in an identifier
a.cc:34:1: error: '\U00003000\U00003000' does not name a type
34 |
| ^~~~
|
s191757327 | p03723 | C++ | #include<stdio.h>
#include<iostream>
#include<string>
#include<math.h>
#include<cmath>
#include<algorithm>
#include<map>
#include<queue>
#include<stack>
#include<vector>
#include<time.h>
#include<ctime>
#include<functional>
#define int long long
#define INT INT_MAX
#define LONG LLONG_MAX
#define f(i,n) for(int i=0;i<(n... | a.cc: In function 'int main()':
a.cc:41:17: error: 'n' was not declared in this scope
41 | cout << n << endl;
| ^
|
s700709678 | p03723 | C++ | #include<bits/stdc++.h>
#define ll long long
#define pb push_back
using namespace std;
const int mnx = 3e5 + 9;
const int mod = 1e9 + 7;
int n, m;
int a, b;
int cnt[mnx];
int main(){
cin>>n>>m;
for(int i=0; i<m; i++){
cin>>a>>b;
cnt[a]++; cnt[b]++;
}
for(int i=1; i<=n; i++){
if(cnt[i] % 2 != 0){
... | a.cc:33:1: error: expected unqualified-id before 'return'
33 | return 0;
| ^~~~~~
a.cc:35:1: error: expected declaration before '}' token
35 | }
| ^
|
s815862934 | p03723 | C | #include<iostream>
using namespace std;
int main()
{
long long A, B, C;
while( cin >> A >> B >> C ){
if(A%2 == 1 || B%2 == 1 || C%2 == 1)
cout << "0" << endl;
else{
long long cnt = 0;
for( ; ; ){
int t1, t2, t3;
t1 = A;
t2 = B;
t3 = C;
A = t2/2 + t3/2;
B = t1/2 + t3/2;
C = t1/... | main.c:1:9: fatal error: iostream: No such file or directory
1 | #include<iostream>
| ^~~~~~~~~~
compilation terminated.
|
s331253651 | p03723 | C++ | #include</dev/console> | a.cc:1:9: fatal error: /dev/console: No such file or directory
1 | #include</dev/console>
| ^~~~~~~~~~~~~~
compilation terminated.
|
s087306283 | p03723 | C++ | #include<con> | a.cc:1:9: fatal error: con: No such file or directory
1 | #include<con>
| ^~~~~
compilation terminated.
|
s229925051 | p03723 | C++ | #include<con> | a.cc:1:9: fatal error: con: No such file or directory
1 | #include<con>
| ^~~~~
compilation terminated.
|
s242129296 | p03723 | C++ | #include<iostream>
#include<cstdio>
#include<algorithm>
using namespace std;
bool compare(int a,int b)
{
return a>b;
}
int main(){
long long double a,b,c,e,f,g;
cin>>a>>b>>c;
int n=0;
while(n<1000000){
n++;
e=a;g=b;f=c;
a=(g+f)/2.0;
b=(e+f)/2.0;
c=(e+g)/2.0;
if(a>(int)a||b>(int)b||c>(int)c){
n--;
... | a.cc: In function 'int main()':
a.cc:10:14: error: 'long long' specified with 'double'
10 | long long double a,b,c,e,f,g;
| ^~~~
a.cc:10:14: error: 'long long' specified with 'double'
a.cc:10:14: error: 'long long' specified with 'double'
a.cc:10:14: error: 'long long' specified with 'doub... |
s918599020 | p03723 | C | #include<iostream>
#include<algorithm>
using namespace std;
int main()
{
int a,b,c,ta,tb;
while(cin>>a>>b>>c){
for(int i=1;;i++){
ta=a;tb=b;
a=b/2+c/2;
b=ta/2+c/2;
c=ta/2+tb/2;
if(a%2==1 || b%2==1 || c%2==1){
cout<<i<<endl;break;
}
if(a==b && a==c){
cout<<"-1"<<endl;break;
}
}
}
return 0;... | main.c:1:9: fatal error: iostream: No such file or directory
1 | #include<iostream>
| ^~~~~~~~~~
compilation terminated.
|
s320705379 | p03723 | C | #include<iostream>
#include<algorithm>
using namespace std;
int main()
{
int a,b,c,ta,tb;
while(cin>>a>>b>>c){
for(int i=1;;i++){
ta=a;tb=b;
a=b/2+c/2;
b=ta/2+c/2;
c=ta/2+tb/2;
if(a%2==1 || b%2==1 || c%2==1){
cout<<i;break;
}
if(a==b && a==c){
cout<<"-1";break;
}
}
}
return 0;
} | main.c:1:9: fatal error: iostream: No such file or directory
1 | #include<iostream>
| ^~~~~~~~~~
compilation terminated.
|
s660838637 | p03723 | Java | a,b,c = map(int, input().split())
for i in range(100):
if a%2==1 or b%2==1 or c%2==1:
break
a, b, c = (a+b)//2,(b+c)//2,(c+a)//2
ans = i
if i == 99:
ans = -1
print(ans)
| Main.java:1: error: class, interface, enum, or record expected
a,b,c = map(int, input().split())
^
1 error
|
s836468082 | p03723 | C++ | #include<iostream>
#include<algorithm>
#include<math.h>
#include<cstdio>
#include<ctype.h>
#include<stdio.h>
#include<set>
#include<vector>
#include<map>
#include<functional>
#include<iomanip>
#include<queue>
#include<ciso646>
#include<random>
#include<numeric>
#include<string>
typedef long long ll;
using namespace std... | a.cc:30:20: error: extended character is not valid in an identifier
30 | cout<<-1<<endl; return 0;
| ^
a.cc: In function 'int main()':
a.cc:30:20: error: '\U00003000return' was not declared in this scope
30 | cout<<-1<<endl; return 0;
| ^~~~~~~~
|
s303227707 | p03723 | C++ | def count(seq):
seq = sorted(seq)
x , y = [seq[1] - seq[0], seq[2] - seq[0]]
if x == 0 and y == 0:
return -1
elif x == 0:
k = x & -x
elif y == 0:
k = y & -y
else:
k = min(x & -x, y & -y)
foo = 0
while (k & 1) == 0:
k >>= 1
foo += 1
retu... | a.cc:22:16: warning: multi-character literal with 8 characters exceeds 'int' size of 4 bytes
22 | if __name__ == '__main__':
| ^~~~~~~~~~
a.cc:1:1: error: 'def' does not name a type
1 | def count(seq):
| ^~~
|
s434991321 | p03723 | C++ | #include <iostream>
using namespace std;
int main(){
int a,b,c;
cin>>a>>b>>c;
if(a==b==c){
cout<<"-1"<<endl;
}
int aa=a,bb=b,cc=c,count=0;
else{
while(a%2==0&&b%2==0&&c%2==0){
a=bb/2+cc/2;
b=cc/2+aa/2;
c=aa/2+bb/2;
aa=a;
bb=b;
cc=c;
count+=1;
}
co... | a.cc: In function 'int main()':
a.cc:10:3: error: 'else' without a previous 'if'
10 | else{
| ^~~~
|
s444789780 | p03723 | C++ | #include <iostream>
#include <algorithm>
#include<string>
#include<cmath>
#include<stack>
#include <vector>
#include<queue>
#include <random>
#include <cstdint>
#include <bitset>
#include <iomanip>
using namespace std;
int main() {
int a[3],b=0;
for (int i = 0; i < 3; i++) {
scanf_s("%d", &a[i]);
a[i] %= 4;
if... | a.cc: In function 'int main()':
a.cc:17:17: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
17 | scanf_s("%d", &a[i]);
| ^~~~~~~
| scanf
|
s128607170 | p03723 | C++ | #include <iostream>
using namespace std;
int main(){
int a,b,c;
cin >> a >> b >> c;
for(int i=0;i<50000000;i++){
if(a%2==1||b%2==1||c%2==1){cout << i << endl; return 0;}
aa = (b+c) / 2;
bb = (a+c) / 2;
cc = (a+b) / 2;
a = aa; b = bb; c = cc;
}
cout << -1 << endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:9:5: error: 'aa' was not declared in this scope; did you mean 'a'?
9 | aa = (b+c) / 2;
| ^~
| a
a.cc:10:5: error: 'bb' was not declared in this scope; did you mean 'b'?
10 | bb = (a+c) / 2;
| ^~
| b
a.cc:11:5: error: 'cc' was no... |
s156011382 | p03723 | C++ | a,b,c=list(map(int,input().split()))
ans=0
while 1:
if a%2!=0 or b%2!=0 or c%2!=0:
print(ans)
break
if a==b and b==c:
print('-1')
break
a,b,c=(b+c)>>1,(a+c)>>1,(a+b)>>2
ans+=1; | a.cc:8:23: warning: multi-character character constant [-Wmultichar]
8 | print('-1')
| ^~~~
a.cc:1:1: error: 'a' does not name a type
1 | a,b,c=list(map(int,input().split()))
| ^
|
s234257604 | p03723 | C++ | a,b,c=list(map(int,input().split()))
if a == b and a == c :
ans = -1
else:
ans = int(0)
while a % 2 == 0 and b % 2 == 0 and c % 2 == 0:
ta = b/2 + c/2
tb = a/2 + c/2
tc = a/2 + b/2
a = ta
b = tb
c = tc
ans += 1
print(ans) | a.cc:1:1: error: 'a' does not name a type
1 | a,b,c=list(map(int,input().split()))
| ^
|
s817288009 | p03723 | C++ | #include<bits/stdc++.h>
#define pi 3.141592653897932384626
//freopen("std.in","r",stdin);freopen("std.out","w",stdout);
using namespace std;
int main()
{
long a,b,c;
cin>>a>>b>>c;
long x,y,z;
long k=0;
if(a%2==1||b%2==1||c%2==1){cout<<k<endl;return 0;}
while(k<10000000){
k++;
x=(... | a.cc: In function 'int main()':
a.cc:11:39: error: no match for 'operator<' (operand types are 'std::basic_ostream<char>::__ostream_type' {aka 'std::basic_ostream<char>'} and '<unresolved overloaded function type>')
11 | if(a%2==1||b%2==1||c%2==1){cout<<k<endl;return 0;}
| ~~... |
s871901821 | p03723 | C++ | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace CookieExchanges {
class Program {
static void Main(string[] args) {
string[] s = Console.ReadLine().Split();
int a = int.Parse(s[0]);
int b = int... | a.cc:1:7: error: expected nested-name-specifier before 'System'
1 | using System;
| ^~~~~~
a.cc:2:7: error: expected nested-name-specifier before 'System'
2 | using System.Collections.Generic;
| ^~~~~~
a.cc:3:7: error: expected nested-name-specifier before 'System'
3 | using System.L... |
s324315410 | p03723 | C++ | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int,int> pii;
int main() {
int a, b, c;
cin >> a >> b >> c;
int a2, b2, c2;
int cnt = 0;
while(a%2==0 && b%2==0 && c%2==0){
a2 = b/2 + c/2;
b2 = a/2 + c/2;
c2 = a/2 + b/2;
if(a==a2 && b... | a.cc: In function 'int main()':
a.cc:24:14: error: expected '}' at end of input
24 | return 0;
| ^
a.cc:6:12: note: to match this '{'
6 | int main() {
| ^
|
s206287256 | p03723 | C++ | import std.stdio;
import std.algorithm;
import std.array;
import std.conv;
import std.string;
import std.math;
void main() {
auto abc = readln.chomp.split.map!(to!int).array;
long a = abc[0], b = abc[1], c = abc[2];
if (a == b && b == c) {
(-1).writeln;
}
else {
int ans;
while (a % 2 == 0 && b... | a.cc:1:1: error: 'import' does not name a type
1 | import std.stdio;
| ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:2:1: error: 'import' does not name a type
2 | import std.algorithm;
| ^~~~~~
a.cc:2:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:3:1... |
s501937025 | p03723 | C++ | #include <iostream>
#include <vector>
#include <queue>
using namespace std;
typedef long long i64;
i64 a,b,c;
int rec(int A,int B,int C)
{
if(A % 2 == 1 || B % 2 == 1 || C % 2 == 1)
return 0;
int p = A / 2;
int q = B / 2;
int r = C / 2;
return rec(q + r , p + r , p + q) + 1;
}
int main()
{
cin >> a >> b >> c... | a.cc: In function 'int main()':
a.cc:23:14: error: lvalue required as left operand of assignment
23 | if(a % 2 = 0 && a == b && b == c)
| ~~^~~
|
s825779632 | p03723 | C++ | #include <iostream>
#include <vector>
#include <queue>
using namespace std;
typedef long long i64;
#define int i64
i64 a,b,c;
signed rec(int A,int B,int C)
{
if(A % 2 == 1 || B % 2 == 1 || C % 2 == 1)
return 0;
int p = A / 2;
int q = B / 2;
int r = C / 2;
return rec(q + r , p + r , p + q) + 1;
}
int main()
{... | a.cc:8:13: error: '::main' must return 'int'
8 | #define int i64
| ^~~
a.cc:21:1: note: in expansion of macro 'int'
21 | int main()
| ^~~
|
s479509703 | p03723 | C++ | #include <bits/stdc++.h>
#define LL long long
#define PII pair
#define MP(x, y) make_pair((x),(y))
#define fi first
#define se second
#define PB(x) push_back((x))
#define MMG(x) memset((x), -1,sizeof(x))
#define MMF(x) memset((x),0,sizeof(x))
#define MMI(x) memset((x), INF, sizeof(x))
using namespace std;
const int I... | a.cc: In function 'int bfs(int, int)':
a.cc:25:5: error: 'queueq' was not declared in this scope
25 | queueq;
| ^~~~~~
a.cc:26:5: error: 'q' was not declared in this scope
26 | q.push(MP(sx, sy));
| ^
|
s229419764 | p03723 | C | #include <bits/stdc++.h>
using namespace std;
#define INF 1001000100010001000
#define MOD 1000000007
#define EPS 1e-10
#define int long long
#define rep(i, N) for (int i = 0; i < N; i++)
#define Rep(i, N) for (int i = 1; i < N; i++)
#define For(i, a, b) for (int i = (a); i < (b); i++)
#define pb push_back
#define eb ... | main.c:1:10: fatal error: bits/stdc++.h: No such file or directory
1 | #include <bits/stdc++.h>
| ^~~~~~~~~~~~~~~
compilation terminated.
|
s987252736 | p03723 | C++ | #include <cstdlib>
#include <cstdio>
#include <vector>
#include <cstring>
#include <iostream>
using namespace std;
const int MAXN=810;
typedef pair<int,int> ii;
vector <ii> v;
int go[4][2]={{0,-1},{0,1},{1,0},{-1,0}};
int n,m,k,sx,sy;
char a[MAXN][MAXN];
int count(int x) { return x%k?(x/k+1):(x/k); }
int make(ii p... | a.cc: In function 'void dfs(int, int, int)':
a.cc:29:9: error: 'book' was not declared in this scope; did you mean 'bool'?
29 | book[x][y]=1;
| ^~~~
| bool
|
s916127937 | p03723 | C++ | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll a,b,c;
int main() {
cin >> a >> b >> c;
if(a == b && b == c && A % 2 == 0) {
cout <<"-1"<<endl;
return 0;
}
ll ans = 0;
while(a % 2 == 0 && b % 2 == 0 && c % 2 == 0) {
ll s = a / 2;
ll t = b / 2;
ll r = c / 2;
... | a.cc: In function 'int main()':
a.cc:12:26: error: 'A' was not declared in this scope
12 | if(a == b && b == c && A % 2 == 0) {
| ^
|
s076574615 | p03723 | C++ | #include<cstdio>
#include<cstring>
#include<vector>
#include<queue>
#include<algorithm>
#include<cmath>
#include<climits>
#include<string>
#include<set>
#include<map>
#include<iostream>
using namespace std;
#define rep(i,n) for(int i = 0;i<((int)(n));i++)
#define reg(i,a,b) for(int i = ((int)(a));i<=((int)(b));i++)
#de... | a.cc: In function 'int main()':
a.cc:31:17: error: 'accumulate' was not declared in this scope
31 | lli n = accumulate(a.begin(), a.end(), 0ll);
| ^~~~~~~~~~
|
s048351642 | p03723 | Java | import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
int c = sc.nextInt();
int i = 0;
if(a == b && b == c && a % 2 == 0 ) {
i = -1;... | Main.java:27: error: package Sysytem does not exist
Sysytem.out.println(i);
^
1 error
|
s357364636 | p03723 | Java | import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
int c = sc.nextInt();
int i = 0;
if(a == b && b == c && a % 2 == 0 ) {
i = -1;
} e... | Main.java:7: error: illegal character: '\u3000'
??int a = sc.nextInt();
^
Main.java:7: error: illegal character: '\u3000'
??int a = sc.nextInt();
^
2 errors
|
s408241397 | p03723 | Java | import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
long a = sc.nextLong();
long b = sc.nextLong();
long c = sc.nextLong();
long i = 0;
while(a % 2 == 0 && b % 2 == 0 && c % 2 == 0) {
... | Main.java:7: error: illegal character: '\u3000'
??long a = sc.nextLong();
^
Main.java:7: error: illegal character: '\u3000'
??long a = sc.nextLong();
^
Main.java:17: error: not a statement
i++;om
^
Main.java:17: error: ';' expected
i++;om
^
4 errors
|
s438932860 | p03723 | Java | import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
double a = sc.nextDouble();
double b = sc.nextDouble();
double c = sc.nextDouble();
double i = 0;
while(a % 2 == 0 && b % 2 == 0 && c % 2 ... | Main.java:7: error: illegal character: '\u3000'
??double a = sc.nextDouble();
^
Main.java:7: error: illegal character: '\u3000'
??double a = sc.nextDouble();
^
2 errors
|
s495947778 | p03723 | Java | import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
int c = sc.nextInt();
int i = 0;
while(a % 2 == 0 && b % 2 == 0 && c % 2 == 0) {
a ... | Main.java:7: error: illegal character: '\u3000'
??int a = sc.nextInt();
^
Main.java:7: error: illegal character: '\u3000'
??int a = sc.nextInt();
^
Main.java:20: error: reached end of file while parsing
}
^
3 errors
|
s790530117 | p03723 | Java | import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
int c = sc.nextInt();
int i = 0;
while(a % 2 == 0 && b % 2 == 0 && c % 2 == 0) {
a ... | Main.java:7: error: illegal character: '\u3000'
??int a = sc.nextInt();
^
Main.java:7: error: illegal character: '\u3000'
??int a = sc.nextInt();
^
Main.java:14: error: not a statement
a == b/2 + c/2;
^
Main.java:15: error: not a statement
b == c/2 + a/2;
^
Main.java:16:... |
s123903209 | p03723 | Java | import java.util.Scanner;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
int c = sc.nextInt();
int i = 0;
while(a % 2 == 0 && b % 2 == 0 && c % 2 == 0) {
a == ... | Main.java:7: error: illegal character: '\u3000'
??int a = sc.nextInt();
^
Main.java:7: error: illegal character: '\u3000'
??int a = sc.nextInt();
^
Main.java:14: error: not a statement
a == b/2 + c/2;
^
Main.java:15: error: not a statement
b == c/2 + a/2;
^
Main.java:16:... |
s371104913 | p03723 | C++ | #include<cstdio>
int main()
{
int a,b,c;
scanf("%d%d%d",&a,&b,&c);
if(a > b) a ^= b ^= a ^= b;
if(b > c) b ^= c ^= b ^= c;
if(a > b) a ^= b ^= a ^= b;
int i;
for(i = 0; i < 32; i ++)
if((a & (1 << i) )||(b & (1 << i)) || (c & & (1 << i)))
break;
if((a == b || b == c) && i > 0)
printf("-1");
else
print... | a.cc: In function 'int main()':
a.cc:11:65: error: lvalue required as unary '&' operand
11 | if((a & (1 << i) )||(b & (1 << i)) || (c & & (1 << i)))
| ~~~^~~~~
|
s031972202 | p03723 | C++ | #include<iostream>
using namespace std;
int main(){
int a[]={}, b[]={}, c[]={};
int counter;
cin >> a[0]>>b[0]>>c[0];
if(a[0]==b[0] && b[0]==c[0]){
cout << -1;
return 0;
}
while(1){
int i;
a[i+1]=(b[i]+c[i])/2;
b[i+1]=(a[i]+c[i])/2;
c[i+1]=(a[i... | 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(){
| ^
|
s738186144 | p03723 | C++ | include<iostream>
using namespace std;
int main(){
int a[]={}, b[]={}, c[]={};
int counter;
cin >> a[0]>>b[0]>>c[0];
if(a[0]==b[0] && b[0]==c[0]){
cout << -1;
return 0;
}
while(1){
int i;
a[i+1]=(b[i]+c[i])/2;
b[i+1]=(a[i]+c[i])/2;
c[i+1]=(a[i]... | a.cc:1:1: error: 'include' does not name a type
1 | include<iostream>
| ^~~~~~~
a.cc: In function 'int main()':
a.cc:8:5: error: 'cin' was not declared in this scope
8 | cin >> a[0]>>b[0]>>c[0];
| ^~~
a.cc:11:9: error: 'cout' was not declared in this scope
11 | cout << -1;
|... |
s904704997 | p03723 | C++ | int main(){
int a[]={},b[]={},c[]={};
int counter=0;
cin >> a[0] >> b[0] >>c[0];
if(a[0]==b[0]&&b[0]==c[0]){
cout << -1<< endl;
return 0;
}
while(1){
int i=0;
a[i+1]=(b[i]+c[i])/2;
b[i+1]=(a[i]+c[i])/2;
c[i+1]=(a[i]+b[i])/2;
counter++;
i++;
if(a[i+1]%2==1|b[i+1]%2==1|c[i+1]%2==1){
cout << c... | a.cc: In function 'int main()':
a.cc:4:9: error: 'cin' was not declared in this scope
4 | cin >> a[0] >> b[0] >>c[0];
| ^~~
a.cc:7:17: error: 'cout' was not declared in this scope
7 | cout << -1<< endl;
| ^~~~
a.cc:7:30: error: 'endl' was not declared ... |
s060072786 | p03723 | C++ | #include "stdafx.h"
#include <stdio.h>
int main()
{
int a[] = { 0,1,3,1,2,1,2,1,1,2,1,2,1 };
int x, y;
scanf("%d", &x);
scanf("%d", &y);
if (a[x] == a[y]) {
printf("YES\n");
}
else { printf("NO\n"); }
return 0;
} | a.cc:1:10: fatal error: stdafx.h: No such file or directory
1 | #include "stdafx.h"
| ^~~~~~~~~~
compilation terminated.
|
s841249490 | p03723 | Java | 454 414 444 | Main.java:1: error: class, interface, enum, or record expected
454 414 444
^
1 error
|
s132609270 | p03723 | Java | package agc014;
public class CookieExchanges {
public static void main(String[] args) {
int a = Integer.parseInt(args[0]);
int b = Integer.parseInt(args[1]);
int c = Integer.parseInt(args[2]);
int nextA, nextB, nextC;
nextA = nextB = nextC = 0;
int times = 0;
while(true){
nextB += a / 2;
... | Main.java:3: error: class CookieExchanges is public, should be declared in a file named CookieExchanges.java
public class CookieExchanges {
^
1 error
|
s273169178 | p03723 | C++ | #include<bits/stdc++.h>
using namespace std;
typedef unsigned long long LL;
const LL base = 1e10;
LL A[2][3];
int solve(){
ST.clear();
LL sum = A[0][0] + A[0][1] + A[0][2];
int f = 0;
LL v;
for(int i=0; ;i++){
sort(A[f], A[f]+3);
v = A[f][0] * base + A[f][1];
if(ST.count(v)){
return -1;
}
S... | a.cc: In function 'int solve()':
a.cc:9:9: error: 'ST' was not declared in this scope
9 | ST.clear();
| ^~
|
s685154761 | p03723 | C++ | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Atcoder
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine(CookieExchanges());
}
public static int CookieExchanges()
... | a.cc:1:7: error: expected nested-name-specifier before 'System'
1 | using System;
| ^~~~~~
a.cc:2:7: error: expected nested-name-specifier before 'System'
2 | using System.Collections.Generic;
| ^~~~~~
a.cc:3:7: error: expected nested-name-specifier before 'System'
3 | using System.L... |
s753805659 | p03723 | C++ | /*AGC*/
#include<stdio.h>
int exchangesCount(int a,int b, int c){
while(a%2==b%2==c%2==0){
int as, bs, cs;
as=(b+c)/2;
bs=(c+a)/2;
cs=(a+b)/2;
i++;
a=as;
b=bs;
c=cs;
if(i>1000000)return -1;
}
return i;
}
int main(){
int a,b,c;
... | a.cc: In function 'int exchangesCount(int, int, int)':
a.cc:10:9: error: 'i' was not declared in this scope
10 | i++;
| ^
a.cc:16:12: error: 'i' was not declared in this scope
16 | return i;
| ^
|
s130277128 | p03723 | C++ | /*AGC*/
#include<stdio.h>
int exchangesCount(int a,int b, int c){
while(a%2==b%2==c%2==0){
as=(b+c)/2;
bs=(c+a)/2;
cs=(a+b)/2;
i++;
a=as;
b=bs;
c=cs;
if(i>1000000)return -1;
}
return i;
}
int main(){
int a,b,c;
scanf("%d %d %d",&a,&b,... | a.cc: In function 'int exchangesCount(int, int, int)':
a.cc:6:9: error: 'as' was not declared in this scope; did you mean 'a'?
6 | as=(b+c)/2;
| ^~
| a
a.cc:7:9: error: 'bs' was not declared in this scope; did you mean 'b'?
7 | bs=(c+a)/2;
| ^~
| ... |
s452031435 | p03723 | C++ | #include<cstdio>
int a, b, c, aNew, bNew, cNew;
int main()
{
scanf("%d%d%d", &a, &b, &c);
int n = 0;
while(!(a&1) && !(b&1) && !(c&1))
{
n++;
aNew = (b + c) >> 1; bNew = (a + c) >> 1; cNew = (a + b) >> 1;
if(a == aNew && b == bNew && c == cNew)
{
printf("%... | a.cc: In function 'int main()':
a.cc:20:20: error: 't' was not declared in this scope
20 | printf("%d\n", t);
| ^
|
s919981812 | p03723 | Java | public static void main(String[] args) {
int val = 11;
if (val == 10) {
System.out.println("変数valは10です");
} else {
System.out.println("変数valは10ではありません");
} // 結果:変数valは10ではありません
} | Main.java:1: error: unnamed classes are a preview feature and are disabled by default.
public static void main(String[] args) {
^
(use --enable-preview to enable unnamed classes)
1 error
|
s857703576 | p03723 | C++ | a , b , c = map(int , raw_input().split())
ans = 0
while not ((a & 1) | (b & 1) | (c & 1)):
a , b , c = (b + c) >> 1 , (a + c) >> 1 , (a + b) >> 1
ans += 1
if ans > 1 << 15:
ans = -1
break
print ans | a.cc:1:1: error: 'a' does not name a type
1 | a , b , c = map(int , raw_input().split())
| ^
|
s682146445 | p03723 | C++ | #include <iostream>
int main(){
int a,b,c;
int cnt=0;
cin >> a >> b >> c;
while(!a%2 || !b%2 || !c%2){
cnt++;
int _a = (b+c)/2;
int _b = (a+c)/2;
int _c = (a+b)/2;
a=_a;b=_b;c=_c;
}
std::cout << cnt ;
} | a.cc: In function 'int main()':
a.cc:8:5: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
8 | cin >> a >> b >> c;
| ^~~
| std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
62 | extern istream cin; //... |
s427446240 | p03723 | C++ | #include <iostream>
#include <cstdio>
#include <algorithm>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <vector>
#pragma warning(disable : 4996)
using namespace std;
#define FOR(i,a,b) for (int i = (a); i < (b); i++)
#define REP(i,n) FOR(i,0,n)
//最大公約数
long gcd(long a, long b){
if (a%b==0){
... | a.cc: In function 'int main()':
a.cc:45:17: error: expected '(' before '{' token
45 | else if{
| ^
| (
|
s741963943 | p03723 | C++ | #include <iostream>
using namespace std;
int A,B,C;
int ans;
int main() {
cin >> A >> B >> C;
if(A == B && B == C && (C % 2 == 0)) {cout << "-1" <<endl; return 0;}
while((A % 2 == 0) && (B % 2 == 0) && (C % 2 == 0)) {
int tmp = A / 2;
int tmp2 = B / 2;
int tmp3 = C / 2;
A = tmp2 + tmp3;
B ... | a.cc:30:5: error: redefinition of 'int A'
30 | int A,B,C;
| ^
a.cc:5:5: note: 'int A' previously declared here
5 | int A,B,C;
| ^
a.cc:30:7: error: redefinition of 'int B'
30 | int A,B,C;
| ^
a.cc:5:7: note: 'int B' previously declared here
5 | int A,B,C;
| ^
a.... |
s246900540 | p03723 | Java | import java.util.Scanner;
public class Main{
public static void main(String[] args){
Scanner scan= new Scanner(System.in);
int a = scan.nextInt();
int b = scan.nextInt();
int c = scan.nextInt();
int count=0;
if(a==b && b==c){
if(a%2==1 && b%2==0 && c%2==0)) count=-1;
}else{
while(a%2==0 && b%2==0 && c%2==0){
in... | Main.java:12: error: illegal start of expression
if(a%2==1 && b%2==0 && c%2==0)) count=-1;
^
1 error
|
s275692276 | p03723 | C++ | #include<iostream>
#include<cstdio>
#include<stdio.h>
#include<cstring>
#include<cstdio>
#include<climits>
#include<cmath>
#include<vector>
#include <bitset>
#include<algorithm>
#include <queue>
#include<map>
#define inf 9999999;
using namespace std;
/*start:2017/5/6 15:38*/
/*end:20... | a.cc: In function 'int main()':
a.cc:26:9: error: 's' was not declared in this scope
26 | s = abs(y - z);
| ^
|
s734006035 | p03723 | C++ | //In the Name of God
//Let Our Voices Echo
#pragma GCC optimize("O3")
#include<bits/stdc++.h>
using namespace std;
#define X real()
#define Y imag()
typedef long long ll;
typedef double ld;
typedef complex<ld> point;
const ld eps=1e-9;
const int MAX=1e5+9,MOD=1e9+7;
int n,d[MAX];
vector<int> g[MAX];
queue<int> q;
int ... | a.cc: In function 'int main()':
a.cc:49:25: error: 'Endl' was not declared in this scope
49 | cout<<"Second"<<Endl;
| ^~~~
|
s860517831 | p03723 | C++ | #include <stdio.h>
int main()
{ int a,b,c,ans;
scanf("%d%d%d",&a,&b,&c);
for(int i=1;;i++){
int q=a/2;
int w=b/2;
int e=c/2;
if(a==b&&b==c&&a!=0&&a%2==0){
ans=-1;
break;
}
if((a%2!=0&&b%2!=0)||(a%2!=0&&c%2!=0)||(c%2!=0&&b%2!=0)){
ans=0... | a.cc: In function 'int main()':
a.cc:47:9: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
47 | int main()
| ^~
a.cc:47:9: note: remove parentheses to default-initialize a variable
47 | int main()
| ^~
| --
a.cc:47:9: note: or repl... |
s235539082 | p03723 | C++ | #include <bits/stdc++.h>
#define ll long long
#define pb push_back
#define mp make_pair
#define F first
#define S second
#define poq pop_back
#define tof ios_base :: sync_with_stdio(NULL);cin.tie(0);cout.tie(0)
using namespace std;
char y[809][809];
bool viz[809][809];
bool vizz[809][809];
int main()
{
ll h,... | a.cc:22:5: error: extended character » is not valid in an identifier
22 | cin»h»w»k;
| ^
a.cc:22:5: error: extended character » is not valid in an identifier
a.cc:22:5: error: extended character » is not valid in an identifier
a.cc:27:13: error: extended character » is not valid in an identifier
27 ... |
s948996075 | p03723 | C++ | #define _CRT_SECURE_CPP_OVERLOAD_SECURE_NAMES 1
#include <sstream>
#include <vector>
#include <string>
#include <algorithm>
#include <numeric>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <random>
#include <ctime>
#de... | a.cc: In function 'int main()':
a.cc:39:23: error: no matching function for call to 'std::mersenne_twister_engine<long unsigned int, 32, 624, 397, 31, 2567483615, 11, 4294967295, 7, 2636928640, 15, 4022730752, 18, 1812433253>::mersenne_twister_engine(std::random_device&)'
39 | mt19937 mt(rnd);
| ... |
s870821265 | p03723 | C++ | #define _CRT_SECURE_CPP_OVERLOAD_SECURE_NAMES 1
#include <sstream>
#include <vector>
#include <string>
#include <algorithm>
#include <numeric>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <random>
#include <ctime>
#de... | a.cc: In function 'int main()':
a.cc:39:23: error: no matching function for call to 'std::mersenne_twister_engine<long unsigned int, 32, 624, 397, 31, 2567483615, 11, 4294967295, 7, 2636928640, 15, 4022730752, 18, 1812433253>::mersenne_twister_engine(std::random_device&)'
39 | mt19937 mt(rnd);
| ... |
s429970570 | p03723 | C++ | #define _CRT_SECURE_CPP_OVERLOAD_SECURE_NAMES 1
#include <sstream>
#include <vector>
#include <string>
#include <algorithm>
#include <numeric>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <random>
#include <ctime>
#de... | a.cc: In function 'int main()':
a.cc:72:23: error: no matching function for call to 'std::mersenne_twister_engine<long unsigned int, 32, 624, 397, 31, 2567483615, 11, 4294967295, 7, 2636928640, 15, 4022730752, 18, 1812433253>::mersenne_twister_engine(std::random_device&)'
72 | mt19937 mt(rnd);
| ... |
s831335549 | p03723 | C++ | using namespace std;
int main(){
int a,b,c,result=0;
while(cin>>a>>b>>c)
{
while(a%2 == 0 && b%2 == 0 && c%2==0 && a!=b && b!=c)
{
result++;
int temp=a;
a=(b+c)/2;
int temp2=b;
b=(temp+c)/2;
c=(temp+temp2)/2;
}
if(result==0) result=-1;
cout<<result<<endl;
}
return 0;
} | a.cc: In function 'int main()':
a.cc:4:15: error: 'cin' was not declared in this scope
4 | while(cin>>a>>b>>c)
| ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
+++ |+#include <iostream>
1 | using namespace ... |
s941949029 | p03723 | C++ | #define _CRT_SECURE_CPP_OVERLOAD_SECURE_NAMES 1
#include <sstream>
#include <vector>
#include <string>
#include <algorithm>
#include <numeric>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <random>
#include <ctime>
#de... | a.cc: In function 'int main()':
a.cc:72:23: error: no matching function for call to 'std::mersenne_twister_engine<long unsigned int, 32, 624, 397, 31, 2567483615, 11, 4294967295, 7, 2636928640, 15, 4022730752, 18, 1812433253>::mersenne_twister_engine(std::random_device&)'
72 | mt19937 mt(rnd);
| ... |
s514345824 | p03723 | C++ | #define _CRT_SECURE_CPP_OVERLOAD_SECURE_NAMES 1
#include <sstream>
#include <vector>
#include <string>
#include <algorithm>
#include <numeric>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <random>
#include <ctime>
#de... | a.cc: In function 'int main()':
a.cc:71:23: error: no matching function for call to 'std::mersenne_twister_engine<long unsigned int, 32, 624, 397, 31, 2567483615, 11, 4294967295, 7, 2636928640, 15, 4022730752, 18, 1812433253>::mersenne_twister_engine(std::random_device&)'
71 | mt19937 mt(rnd);
| ... |
s661145426 | p03723 | C++ | #define _CRT_SECURE_CPP_OVERLOAD_SECURE_NAMES 1
#include <sstream>
#include <vector>
#include <string>
#include <algorithm>
#include <numeric>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <random>
#include <ctime>
#de... | a.cc: In function 'int main()':
a.cc:71:23: error: no matching function for call to 'std::mersenne_twister_engine<long unsigned int, 32, 624, 397, 31, 2567483615, 11, 4294967295, 7, 2636928640, 15, 4022730752, 18, 1812433253>::mersenne_twister_engine(std::random_device&)'
71 | mt19937 mt(rnd);
| ... |
s940867964 | p03723 | C++ | //satyaki3794
#include <bits/stdc++.h>
#define ff first
#define ss second
#define pb push_back
#define MOD (1000000007LL)
#define LEFT(n) (2*(n))
#define RIGHT(n) (2*(n)+1)
using namespace std;
typedef long long ll;
typedef pair<int, int> ii;
typedef pair<ii, int> iii;
ll pwr(ll base, ll p, ll mod){
ll ans = 1;while... | a.cc: In function 'int main()':
a.cc:76:35: error: 'vv' was not declared in this scope; did you mean 'v'?
76 | for(auto it : adj[vv])
| ^~
| v
|
s314338004 | p03723 | C++ | #include<bits/stdc++.h>
using namespace std;
int main()
{
int a,b,c,m,n,flag=0;
cin>>a>>b>>c;
while(a%2==0 && b%2==0 && c%2==0){
m=a;
n=b
a=c/2+b/2;
b=c/2+m/2;
c=n/2+m/2;
flag++;
}
cout<<flag;
} | a.cc: In function 'int main()':
a.cc:9:10: error: expected ';' before 'a'
9 | n=b
| ^
| ;
10 | a=c/2+b/2;
| ~
|
s730912126 | p03723 | C | #include<stdio.h>
#include<stdlib.h>
int main()
{
long long int a,b,c;
long long int x,y,z;
scanf("%lld %lld %lld",&a,&b,&c);
long long int flag = 0;
for(1)
{
x=a;
y=b;
z=c;
a= y/2 + z/2;
b = x/2 + z/2;
c = x/2 + y/2;
flag ++;
if(a%2==1 && b%2 == 1 && c%2 ==1)
break;
}
printf("%lld",flag);
r... | main.c: In function 'main':
main.c:9:14: error: expected ';' before ')' token
9 | for(1)
| ^
| ;
main.c:9:14: error: expected expression before ')' token
|
s142832000 | p03723 | C++ | #include <iostream>
using namespace std;
int main() {
// your code goes here
int A,B,C,i,a,b,c;
cin>>A>>B>>C;
for ( i=0; i++;);
int a[0]=A;
b[0]=B;
c[0]=C;
a[i]=a[i-1]/2;
b[i]=b[i-1]/2;
c[i]=c[i-1]/2;
if (a[i]%2!=0||b[i]%2!=0||c[i]%2!=0)cout<<"i"<<endl;
else cout<<"-1"<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:9:13: error: conflicting declaration 'int a [0]'
9 | int a[0]=A;
| ^
a.cc:6:21: note: previous declaration as 'int a'
6 | int A,B,C,i,a,b,c;
| ^
a.cc:10:10: error: invalid types 'int[int]' for array subscript
10 ... |
s583030042 | p03723 | C++ | #include <stdio.h>
int main()
{ int a,b,c,ans;
scanf("%d%d%d",&a,&b,&c);
for(int i=1;;i++){
int q=a/2;
int w=b/2;
int e=c/2;
if(a==b&&b==c||q=0||w=0||e=0){
ans=-1;
break;
}
if(i>20000){
ans=-1;
break;
}
if... | a.cc: In function 'int main()':
a.cc:10:32: error: lvalue required as left operand of assignment
10 | if(a==b&&b==c||q=0||w=0||e=0){
| ~^~~
|
s216588392 | p03723 | C++ | def sort(n1, n2, n3):
n=[n1, n2, n3]
t=len(n)
for i in range(t-1):
for j in range(i+1, t):
if n[i] > n[j]:
n[i],n[j] = n[j],n[i]
return n
if __name__ == '__main__':
A, B, C=map(int, input().split())
N=0
arr=[]
flag=1
if(A%2==1 or B%2==1 or C%2==1):
flag=0
while(flag):
A, B, C = sort(A,B,C)
ar... | a.cc:10:16: warning: multi-character literal with 8 characters exceeds 'int' size of 4 bytes
10 | if __name__ == '__main__':
| ^~~~~~~~~~
a.cc:1:1: error: 'def' does not name a type
1 | def sort(n1, n2, n3):
| ^~~
|
s470520532 | p03723 | C | #include<stdio.h>
int separate(int,int,int);
int main(){
int a,b,c;
scanf("%d %d %d",&a,&b,&c);
printf("%d",separate(a,b,c));
return 0;
}
int separate(int a,int b,int c){
int i;
int a2,b2,c2;
const int MAX = 1000000000;
for(i = 1 ,i<=MAX; i++){
a2 = a/2;
b2 = b/2;
c2 = c/2;
a = b2 + c2;
b = a2 + c2;
c = a2 ... | main.c: In function 'separate':
main.c:23:23: error: expected ';' before ')' token
23 | for(i = 1 ,i<=MAX; i++){
| ^
| ;
|
s963465760 | p03723 | C | #include<stadio.h>
int separate(int,int,int);
int main(){
int a,b,c;
scanf("%d %d %d",&a,&b,&c);
printf("%d",separate(a,b,c));
return 0;
}
int separate(int a,int b,int c){
int i;
int a2,b2,c2;
const double MAX = 1000000000;
for(i = 1 ,i<=MAX; i++){
a2 = a/2;
b2 = b/2;
c2 = c/2;
a = b2 + c2;
b = a2 + c2;
c =... | main.c:1:9: fatal error: stadio.h: No such file or directory
1 | #include<stadio.h>
| ^~~~~~~~~~
compilation terminated.
|
s703949323 | p03723 | C | #include<stadio.h>
int separate(int,int,int);
int main(){
int a,b,c;
scanf("%d %d %d",&a,&b,&c);
printf("%d",separate(a,b,c));
return 0;
}
int separate(int a,int b,int c){
int i;
int a2,b2,c2;
const int MAX = 1000000000;
for(i = 1 ,i<=MAX; i++){
a2 = a/2;
b2 = b/2;
c2 = c/2;
a = b2 + c2;
b = a2 + c2;
c = a2... | main.c:1:9: fatal error: stadio.h: No such file or directory
1 | #include<stadio.h>
| ^~~~~~~~~~
compilation terminated.
|
s051984834 | p03723 | C++ | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace test
{
class Program
{
static void Main(string[] args)
{
string[] str = Console.ReadLine().Split(' ');
int[] D = new int[3];
D[0] = i... | a.cc:1:7: error: expected nested-name-specifier before 'System'
1 | using System;
| ^~~~~~
a.cc:2:7: error: expected nested-name-specifier before 'System'
2 | using System.Collections.Generic;
| ^~~~~~
a.cc:3:7: error: expected nested-name-specifier before 'System'
3 | using System.L... |
s402935582 | p03723 | C++ | #include <cstdio>
#include <iostream>
#include <cstdlib>
#include <algorithm>
#include <vector>
#include <cstring>
#include <queue>
#include <stack>
#include <functional>
#include <set>
#include <map>
#include <deque>
#define WMAX 10000
#define HMAX 100000007
//コメントアウトするとdebug()を実行しない
#define DEBUG
using namespace st... | /tmp/cc8txrjM.o: in function `__static_initialization_and_destruction_0()':
a.cc:(.text+0x225): relocation truncated to fit: R_X86_64_PC32 against symbol `S[abi:cxx11]' defined in .bss section in /tmp/cc8txrjM.o
a.cc:(.text+0x23e): relocation truncated to fit: R_X86_64_PC32 against symbol `S[abi:cxx11]' defined in .bss... |
s021811216 | p03723 | C++ | #include <stdio.h>
#include <algorithm>
int main() {
int A, B, C;
scanf("%d %d %d", &A, &B, &C);
int time = 0;
while ((A % 2 == 0 && B % 2 == 0 && C % 2 == 0) && !(A == B && B == C && C == A)) {
time++;
int TA = (B + C) / 2;
int TB = (A + C) / 2;
int TC = (A + B) / 2;
A = TA;
B = TB;
C = TC;
}
if (... | a.cc: In function 'int main()':
a.cc:20:2: error: expected '}' at end of input
20 | }
| ^
a.cc:4:12: note: to match this '{'
4 | int main() {
| ^
|
s572380088 | p03723 | C | #include<stadio.h>
int separate(int,int,int);
int main(){
int a,b,c;
scanf("%d %d %d",&a,&b,&c);
printf("%d",separate(a,b,c));
return 0;
}
int separate(int a,int b,int c){
int i;
int a2,b2,c2;
const int MAX = 1000000000;
for(i = 1 ,i<=MAX; i++){
a2 = a/2;
b2 = b/2;
c2 = c/2;
a = b2 + c2;
b = a2 + c2;
c = a2... | main.c:1:9: fatal error: stadio.h: No such file or directory
1 | #include<stadio.h>
| ^~~~~~~~~~
compilation terminated.
|
s546449200 | p03723 | C++ | #include<iostream>
#include<vector>
#include<tr1/unordered_map>
#include<queue>
#include<list>
#include<cmath>
#include<algorithm>
#include<string>
#include<time.h>
using namespace std;
using namespace std::tr1;
bool noOdd(int a, int b, int c){
if((a&1) || (b&1) || (c&1)) return false;
return true;
}
bool equal(... | a.cc:18:31: error: 'c' has not been declared
18 | bool equal(int a, int b, int, c){
| ^
a.cc: In function 'bool equal(int, int, int, int)':
a.cc:19:27: error: 'c' was not declared in this scope
19 | return a==b && b==c;
| ^
In file includ... |
s850535725 | p03723 | C++ | int a,b,c;
cin >> a >> b >> c;
if (!(a%2==0 && b%2 ==0 && c%2==0)) {
cout << "0" << endl;
return 0;
}
int cnt = 0;
if (a%4 != 0)
++cnt;
if (b%4 != 0)
++cnt;
if (c%4!= 0)
++cnt;
if (cnt == 3) {
cout << "-1" << endl;
return 0;
}
... | a.cc:2:5: error: 'cin' does not name a type
2 | cin >> a >> b >> c;
| ^~~
a.cc:3:5: error: expected unqualified-id before 'if'
3 | if (!(a%2==0 && b%2 ==0 && c%2==0)) {
| ^~
a.cc:8:5: error: expected unqualified-id before 'if'
8 | if (a%4 != 0)
| ^~
a.cc:10:5: error... |
s785204839 | p03723 | C++ | #include<iostream>
#include<vector>
#include<sstream>
#include<string>
#include<iomanip>
#include<algorithm>
using namespace std;
int main() {
int A,B,C;
cin >> A >> B >> C;
int count = 0;
int Ablock[3] = {};
int Bblock[3] = {};
int Cblock[3] = {};
Ablock[0] = A; Bblock[0] = B; Cblock[0] = C;
while(1){
if (... | a.cc: In function 'int main()':
a.cc:22:95: error: lvalue required as left operand of assignment
22 | else if (count > 2 && (Ablock[count % 3] = A && Bblock[count % 3] = B && Cblock[count % 3] = C)) {
| ... |
s005937594 | p03723 | C++ | int main()
{
int a, b, c;
cin >> a >> b >> c;
cout << -1 << endl;
return 0;
}
| a.cc: In function 'int main()':
a.cc:4:9: error: 'cin' was not declared in this scope
4 | cin >> a >> b >> c;
| ^~~
a.cc:5:9: error: 'cout' was not declared in this scope
5 | cout << -1 << endl;
| ^~~~
a.cc:5:23: error: 'endl' was not declared in this scope
5 | ... |
s394714319 | p03723 | C++ | #include <iostream>
#include <string>
#include <algorithm>
#include <cstdio>
#include <vector>
#include <queue>
#include <set>
#include <numeric>
#include <cmath>
using namespace std;
typedef long long int lld;
const lld mod = 1e9+7;
const lld INF = 1e9;
const lld MAXN = 1e9;
int main()
{
lld a,b,c;
cin >> a >>b ... | a.cc: In function 'int main()':
a.cc:26:33: error: 'cnt' was not declared in this scope; did you mean 'int'?
26 | cout << cnt << endl;
| ^~~
| int
|
s841741558 | p03723 | Java | import java.util.Scanner;
public class a{
public static void main(String[] args){
Scanner scan= new Scanner(System.in);
int a = scan.nextInt();
int b = scan.nextInt();
int c = scan.nextInt();
int count=0;
if(a==b && b==c){
System.out.println("-1");
}else{
while(a%2==0 && b%2==0 && c%2==0){
int a1=a;
int b1=b;
in... | Main.java:3: error: class a is public, should be declared in a file named a.java
public class a{
^
1 error
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.