submission_id stringlengths 10 10 | problem_id stringlengths 6 6 | language stringclasses 3
values | code stringlengths 1 522k | compiler_output stringlengths 43 10.2k |
|---|---|---|---|---|
s932047596 | p04033 | C | #incldue<stdio.h>
int main(void){
int a,b;
scanf("%d%d",&a,&b);
if(a>0&&b>0)printf("Positive");
else if(a<=0&&b>=0)printf("Zero");
else if(a<0&&b<0)printf("Positive");
return 0;
} | main.c:1:2: error: invalid preprocessing directive #incldue; did you mean #include?
1 | #incldue<stdio.h>
| ^~~~~~~
| include
main.c: In function 'main':
main.c:4:3: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
4 | scanf("%d%d",&a,&b);
| ^~~~~
main.c:... |
s959782120 | p04033 | C++ | #include <bits/stdc++.h>
#define int long long
#define pb push_back
#define l first
#define r second
using namespace std;
const int maxn =
signed main() {
ios_base::sync_with_stdio(0);
cin.tie(0); cout.tie(0);
int a, b; cin >> a >> b;
if (a > 0) cout << "Positive";
else if (a * b <= 0) cout << "Ze... | a.cc:10:1: error: expected primary-expression before 'signed'
10 | signed main() {
| ^~~~~~
|
s446239295 | p04033 | C++ | #include<iostream>
#include<algorithm>
#include<cmath>
#include<cstdio>
#include<string>
#include<cstring>
#include<cstdlib>
using namespace std;
long long a,b;
int main()
{
cin>>a>>b;
else if(b>=0&&a<=0)cout<<"Zero"<<endl;
else if(a>0)cout<<"Positive"<<endl;
else if(abs(b-a+1)%2==1)cout<<"Nega... | a.cc: In function 'int main()':
a.cc:13:3: error: 'else' without a previous 'if'
13 | else if(b>=0&&a<=0)cout<<"Zero"<<endl;
| ^~~~
|
s113123579 | p04033 | C++ | // 002 A - Range Product 2016/07/31
#include <bits/stdc++.h>
#define rep(i ,n) for(int i=0;i<(int)(n);++i)
using namespace std;
typedef long long int int64;
typedef unsigned long long uint64;
int main(){
int64 a , b; cin >> a >> b;
int64 pruduct=1;
for(int i=a ; i <=b ; ++i ){
if(i==0) { cout << 0 ... | a.cc: In function 'int main()':
a.cc:13:9: error: 'product' was not declared in this scope; did you mean 'pruduct'?
13 | product*=i;
| ^~~~~~~
| pruduct
a.cc:15:8: error: 'product' was not declared in this scope; did you mean 'pruduct'?
15 | if(product > 0 ) cout << "Positi... |
s917516812 | p04033 | C++ | #include <iostream>
using namespace std;
int main()
{
int a, b, sum = 1;
cin >> a >> b;
for(int i = a; i <= b; i++)
{
sum *= i;
}
if(sum > 0)
{
cout << "Positive";
}
else if(num < 0)
{
cout << "Negative";
}
else
{
cout << "Zero";
}
return 0;
} | a.cc: In function 'int main()':
a.cc:15:17: error: 'num' was not declared in this scope; did you mean 'sum'?
15 | else if(num < 0)
| ^~~
| sum
|
s286496577 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main() {
int a, b, sum = 1;
cin >> a >> b;
for(int i = a; i <= b; i++)
{
sum *= i;
}
if(sum > 0) cout << "Positive";
else if(num < 0) cout << "Negative";
else cout << "Zero";
return 0;
} | a.cc: In function 'int main()':
a.cc:11:13: error: 'num' was not declared in this scope; did you mean 'sum'?
11 | else if(num < 0) cout << "Negative";
| ^~~
| sum
|
s685256511 | p04033 | C++ | #include<iostream>
#include<cmath>
using namespace std;
int main()
{
int a,b,s=1;
cin>>a>>b;
if(a>0)
cout<<"Positive"<<endl;
else
if(a==0||a<0&&b>0)
cout<<"Zero"<<endl;
else
if((abs(b)-abs(a))2!=0)
cout<<"Positive"<<endl;
else
... | a.cc: In function 'int main()':
a.cc:14:31: error: expected ')' before numeric constant
14 | if((abs(b)-abs(a))2!=0)
| ~ ^
| )
|
s977492101 | p04033 | C++ | #include<iostream>
using namespace std;
int main()
{
int a,b,s=1;
cin>>a>>b;
if(a>0)
cout<<"Positive"<<endl;
else
if(a==0||a<0&&b>0)
cout<<"Zero"<<endl;
else
if((abs(b)-abs(a))2!=0)
cout<<"Positive"<<endl;
else
cout<<"... | a.cc: In function 'int main()':
a.cc:13:31: error: expected ')' before numeric constant
13 | if((abs(b)-abs(a))2!=0)
| ~ ^
| )
|
s317761619 | p04033 | C++ | #include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#define ll long long
#define vi vector<int>
#define pi pair<int, int>
#define pb push_back
#define ppb pop_back
#pragma comment(linker, "/stack:200000000")
#pragma GCC optimize("Ofast")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tu... | a.cc: In function 'int main()':
a.cc:29:37: error: expected ';' before 'else'
29 | if(a < 0) cout << "Negative"
| ^
| ;
30 | else if(a > 0) cout << "Positive";
| ~~~~
|
s503344048 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int main () {
int a, b;
cin >> a >> b;
if(a > 0 && b > 0)cout << "Positive" << endl;
else if(a <= 0 && 0 <= b)cout << "Zero" << endl;
else cout << ((b - a + 1) % 2 == 0?"Positive":"Negative");
cout << << endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:9:12: error: expected primary-expression before '<<' token
9 | cout << << endl;
| ^~
|
s532049047 | p04033 | C++ | #include<iostream>
using namespace std;
int main()
{
long long a,b;
cin>>a>>b;
if((a>0&&b<0)||(a<0&&b>0))cout<<"Zero";
else if(a>0&&b>0)cout<<"Positive";
else if(a<0&&b<0)
if((a-b)%2=!0)cout<<"Nagative";
else cout<<"Positive";
else if(a==0||b==0)cout<<"Zero";
} | a.cc: In function 'int main()':
a.cc:10:13: error: lvalue required as left operand of assignment
10 | if((a-b)%2=!0)cout<<"Nagative";
| ~~~~~^~
|
s435832052 | p04033 | C++ | #include<bits/stdc++.h">
using namespace std;
int a,b;
int main(){
cin>>a>>b;
if(a>0)cout<<"Positive";
else if(a==0||(a<0&&b>0))cout<<"Zero";
else if((abs(b)-abs(a))%2!=0)cout<<"Positive";
else cout<<"Negative";
return 0;
} | a.cc:1:9: fatal error: bits/stdc++.h": No such file or directory
1 | #include<bits/stdc++.h">
| ^~~~~~~~~~~~~~~~
compilation terminated.
|
s628049566 | p04033 | C++ | #include"bits/stdc++.h"
using namespace std;
int a,b;
int main(){
cin>>a>>b;
if(a>0)cout<<"Positive";
else if(a==0||(a<0&&b>0))cout<<"Zero";
else if((abs(b)-abs(a))%2!=0)cout<<"Positive";
else cout<<"Negative";
return 0;
} | a.cc: In function 'int main()':
a.cc:12:1: error: '\U0000ff5d' was not declared in this scope
12 | }
| ^~
a.cc:12:3: error: expected '}' at end of input
12 | }
| ^
a.cc:5:11: note: to match this '{'
5 | int main(){
| ^
|
s081056731 | p04033 | C++ | #include"bits/stdc++.h"
using namespace std;
int a,b;
int main(){
cin>>a>>b;
if(a>0)cout<<"Positive";
else if(a==0||(a<0&&b>0))cout<<"Zero";
else if((abs(b)-abs(a))%2!=0)cout<<"Positive";
else cout<<"Negative";
return 0; | a.cc: In function 'int main()':
a.cc:11:14: error: expected '}' at end of input
11 | return 0;
| ^
a.cc:5:11: note: to match this '{'
5 | int main(){
| ^
|
s351996727 | p04033 | C++ | #include<bits/stdc++.h>
#define rep(i,n) for(int i=0; i<(n); i++)
#define reps(i,n) for(int i=1; i<(n); i++)
#define pii pair<int,int>
#define gsort(x,n) sort((x),(x)+(n),greater<int>())
#define all(x) (x).begin(), (x).end()
#define int int64_t
#define ll long long
#define re(s) reverse((s).begin(),(s).end())
#define ... | a.cc:31:6: error: stray '#' in program
31 | }#include<bits/stdc++.h>
| ^
a.cc: In function 'int main()':
a.cc:31:7: error: 'include' was not declared in this scope
31 | }#include<bits/stdc++.h>
| ^~~~~~~
a.cc:31:15: error: 'bits' was not declared in this scope
31 | }#include<... |
s315846514 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
long long a,b;
cin>>a>>b;
if(a>=1){
cout << "Positive";
}
else if(b<=-1&&(b-a)%2==1){
cout << "Positive";
}
else if(b<=-1&&(b-a)%2==0){
cout << "Negative";
}
else{
cout << "Zero";
}
cout << endl;
| a.cc: In function 'int main()':
a.cc:18:16: error: expected '}' at end of input
18 | cout << endl;
| ^
a.cc:3:11: note: to match this '{'
3 | int main(){
| ^
|
s262060221 | p04033 | C++ | -3 -1 | a.cc:1:1: error: expected unqualified-id before '-' token
1 | -3 -1
| ^
|
s954877639 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
int a,b;
cin>>a>>b;
x=min(a,b); y=max(a,b);
int sum=1;
for(int i=x;i<=y;i++) sum*=i;
if(sum>0) printf("Positive\n");
else if(sum<0) printf("Negative\n");
else printf("Zero");
return 0;
} | a.cc: In function 'int main()':
a.cc:6:9: error: 'x' was not declared in this scope
6 | x=min(a,b); y=max(a,b);
| ^
a.cc:6:21: error: 'y' was not declared in this scope
6 | x=min(a,b); y=max(a,b);
| ^
|
s488561904 | p04033 | C++ | include<bits/stdc++.h>
using namespace std;
#define ll long long
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
ll a,b; cin >> a >> b;
if (a > 0) cout << "Positive" << endl;
else if (a <= 0 && b >= 0) cout << "Zero" << endl;
else {
ll n = b-a+1;
if (n%2 == 1) cout << "Negative" << endl... | a.cc:1:1: error: 'include' does not name a type
1 | include<bits/stdc++.h>
| ^~~~~~~
a.cc: In function 'int main()':
a.cc:6:3: error: 'ios' has not been declared
6 | ios::sync_with_stdio(false);
| ^~~
a.cc:7:3: error: 'cin' was not declared in this scope
7 | cin.tie(nullptr);
| ^~~... |
s435766213 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std
int main()
{
int a,b,c=0;
cin>>a>>b;
if(a>0&&b>0)//如果相乘得数都为正,则直接输出Positive
{
cout<<"Positive";
return 0;
}
else if(a<0&&b<0)/*如果都为负,分相乘的数是积数,则输出Negative,否则输出Positive*/
{
c=b-a+1;
if(c%2!=0)cout<<"Negative";
else cout<<"Positive";
return 0;
}
else if... | a.cc:2:20: error: expected ';' before 'int'
2 | using namespace std
| ^
| ;
3 | int main()
| ~~~
a.cc: In function 'int main()':
a.cc:10:16: error: unable to find numeric literal operator 'operator""\U0000ff1b'
10 | return 0;
... |
s746774393 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std
int main()
{
int a,b,c=0;
cin>>a>>b;
if(a>0&&b>0)//如果相乘得数都为正,则直接输出Positive
{
cout<<"Positive";
return 0;
}
else if(a<0&&b<0)/*如果都为负,分相乘的数是积数,则输出Negative,否则输出Positive*/
{
c=b-a+1;
if(c%2!=0)cout<<"Negative";
else cout<<"Positive";
return 0;
}
else if... | a.cc:2:20: error: expected ';' before 'int'
2 | using namespace std
| ^
| ;
3 | int main()
| ~~~
a.cc: In function 'int main()':
a.cc:10:16: error: unable to find numeric literal operator 'operator""\U0000ff1b'
10 | return 0;
... |
s980454938 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
long long a, b;
cin >> a >> b;
if(a*b <= 0) cout << "Zero" << endl;
else{
if(min(a, b) > 0) cout << "Positive" << endl;
else{
if(abs(a-b)%2 == 1) cout << "Positive" << endl;
else cout << "Negative" << endl;
}
return 0;
} | a.cc: In function 'int main()':
a.cc:17:2: error: expected '}' at end of input
17 | }
| ^
a.cc:4:11: note: to match this '{'
4 | int main(){
| ^
|
s168540058 | p04033 | C++ | #include iostream
using namespace std;
int main() {
long long a, b;
cin >> a >> b;
if (a < 0 && b > 0) {
cout << "Zero";
}
else if (a < 0 && b < 0) {
if ((a - b - 1) % 2 == 0) {
cout << "Positive";
}
else {
cout << "Negative";
}
}
else {
cout << "Positive";
}
} | a.cc:1:10: error: #include expects "FILENAME" or <FILENAME>
1 | #include iostream
| ^~~~~~~~
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope
6 | cin >> a >> b;
| ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixa... |
s114542997 | p04033 | C++ | #include bits/stdc++.h
using namespace std;
int main() {
long long a, b;
cin >> a >> b;
if (a < 0 && b > 0) {
cout << "Zero";
}
else if (a < 0 && b < 0) {
if ((a - b - 1) % 2 == 0) {
cout << "Positive";
}
else {
cout << "Negative";
}
}
else {
cout << "Positive";
}
} | a.cc:1:10: error: #include expects "FILENAME" or <FILENAME>
1 | #include bits/stdc++.h
| ^~~~
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope
6 | cin >> a >> b;
| ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fix... |
s575650235 | p04033 | C++ | #include bits/stdc++.h
using namespace std;
int main() {
cin >> a >> b;
if (a < 0 && b > 0) {
cout << "Zero";
}
else if (a < 0 && b < 0) {
if ((a - b - 1) % 2 == 0) {
cout << "Positive";
}
else {
cout << "Negative";
}
}
else {
cout << "Positive";
}
} | a.cc:1:10: error: #include expects "FILENAME" or <FILENAME>
1 | #include bits/stdc++.h
| ^~~~
a.cc: In function 'int main()':
a.cc:5:3: error: 'cin' was not declared in this scope
5 | cin >> a >> b;
| ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fix... |
s012698030 | p04033 | C++ | #include bits/stdc++.h
using namespace std;
int main() {
cin >> a >> b;
if (a < 0 && b > 0) {
cout << "Zero";
}
else if (a < 0 && b < 0) {
if ((a - b - 1) % 2 == 0) {
cout << "Positive";
}
else {
cout << "Negative";
}
}
else {
cout << "Positive";
}
} | a.cc:1:10: error: #include expects "FILENAME" or <FILENAME>
1 | #include bits/stdc++.h
| ^~~~
a.cc: In function 'int main()':
a.cc:5:3: error: 'cin' was not declared in this scope
5 | cin >> a >> b;
| ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fix... |
s245311770 | p04033 | C++ | #include<bits/stdc++.h>
//compiling code: g++ test.cpp(file) -o script(output) -std=c++11(version) -O2(make it 2x faster)
using namespace std;
int a, b, b2, total;
int main(){
cin >> a >> b;
int value = a;
if (b < 0){
b2 = -b;
} else{
b2 = b;
}
for(int i=0; i<b; i++){
... | a.cc: In function 'int main()':
a.cc:18:23: error: expected ';' before '}' token
18 | value += 1
| ^
| ;
19 | }
| ~
a.cc: At global scope:
a.cc:22:5: error: expected unqualified-id before 'if'
22 | if (t... |
s215664580 | p04033 | C++ | #include<iostream>
using namespace std;
int main()
{
int a,b,s=1;
cin>>a>>b;
for(;a<=b;b++)s*=b;
if(s>0)cout<<"Positive";
if(s==0)cout<<"Zero";
if(s<0)cout<<"Negative";
return 0;
} | a.cc: In function 'int main()':
a.cc:8:18: error: unable to find string literal operator 'operator""\U0000ff1b' with 'const char [9]', 'long unsigned int' arguments
8 | if(s>0)cout<<"Positive";
| ^~~~~~~~~~~~
|
s980416227 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int main()
{
cin>>a>>b;
if (a+b>0) {
cout << "Positive";
}
else if (a+b==0) {
cout << "Zero";
}
else {
cout << "Negative";
}
} | a.cc: In function 'int main()':
a.cc:5:8: error: 'a' was not declared in this scope
5 | cin>>a>>b;
| ^
a.cc:5:11: error: 'b' was not declared in this scope
5 | cin>>a>>b;
| ^
|
s636451913 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int main()
{
cin>>a>>b;
if (a+b>0) {
cout >> "Positive";
}
else if (a+b==0) {
cout >> "Zero";
}
else {
cout >> "Negative";
}
} | a.cc: In function 'int main()':
a.cc:5:8: error: 'a' was not declared in this scope
5 | cin>>a>>b;
| ^
a.cc:5:11: error: 'b' was not declared in this scope
5 | cin>>a>>b;
| ^
a.cc:7:8: error: no match for 'operator>>' (operand types are 'std::ostream' {aka 'std::basic_ostream<ch... |
s835665807 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int a,b;
int main(){
cin >> a >> b;
if (a<0){
if (b>=0){
cout << "Zero";
}
else{
if((b-a)%2 == 1){
cout << "Negative";
}
else{
cout << "Positive";
}
}
}
else{
cout << "Positive";
}
return 0:
} | a.cc: In function 'int main()':
a.cc:25:9: error: expected ';' before ':' token
25 | return 0:
| ^
| ;
a.cc:25:9: error: expected primary-expression before ':' token
|
s750569799 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
//create arrays outside of main()
int a[50] = {};
int main()
{
int a, b;
cin >> a >> b;
int answer = a;
for (int i = a + 1; i < b + 1; i++)
{
answer = answer * i;
}
if (answer > 0)
{
cout << "Positive";
}
else i... | a.cc:35:2: error: expected declaration before '}' token
35 | }}
| ^
|
s854439862 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
//create arrays outside of main()
int a[50] = {};
int main()
{
int a, b;
cin >> a >> b;
int answer = a;
for (int i = a + 1; i < b + 1; i++)
{
answer = answer * i;
}
if (answer > 0)
{
cout << "Positive";
}
else i... | a.cc:35:2: error: expected declaration before '}' token
35 | }}
| ^
|
s043658250 | p04033 | Java | import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int A = sc.nextInt();
int B = sc.nextInt();
if (A == 0 || B == 0 || (A < 0 && B > 0)) {
System.out.println("Zero");
} else if ((A > 0 && B > 0) || ((B-A+1)%2 == 0) {
S... | Main.java:10: error: ')' expected
} else if ((A > 0 && B > 0) || ((B-A+1)%2 == 0) {
^
1 error
|
s313300840 | p04033 | C++ | #include<iostream>
#include<fstream>
#include<algorithm>
using namespace std;
int a,b;
int main(){
cin>>a>>b;
if(a>0)cout<<"Positive";
else
{
if(a==0||(a<0&&b>0))cout<<"Zero";
}
else
{
if((abs(b)-abs(a))%2!=0)cout<<"Positive";
}
else
{
cout<<"Negative";
}
return 0;
} | a.cc: In function 'int main()':
a.cc:13:5: error: 'else' without a previous 'if'
13 | else
| ^~~~
a.cc:17:5: error: 'else' without a previous 'if'
17 | else
| ^~~~
|
s270500662 | p04033 | C++ | #include<iostream>
#include<fstream>
#include<algorithm>
using namespace std;
long long a,b;
int main(){
cin>>a>>b;
if(a>0)cout<<"Positive";
else
{
if(a==0||(a<0&&b>0))cout<<"Zero";
}
else
{
if((abs(b)-abs(a))%2!=0)cout<<"Positive";
}
else
{
cout<<"Negative";
}
return 0;
} | a.cc: In function 'int main()':
a.cc:13:5: error: 'else' without a previous 'if'
13 | else
| ^~~~
a.cc:17:5: error: 'else' without a previous 'if'
17 | else
| ^~~~
|
s128021453 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main()
{
int n,m;
unsigned long long s=1;
cin>>n>>m;
for(register int i=n;i<=m;i++)
s*=i;
if(s<0) cout<<"Negative\n";
if(s>0) cout<<"Positive\n";
else cout<<"Zero\n"
return 0;
} | a.cc: In function 'int main()':
a.cc:8:22: warning: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
8 | for(register int i=n;i<=m;i++)
| ^
a.cc:12:24: error: expected ';' before 'return'
12 | else cout<<"Zero\n"
| ^
| ... |
s722620858 | p04033 | C++ | //优先队列priority_queue<int>j
#include<iostream>
#include<cctype>
#include<algorithm>
#include<cmath>
#include<cstdio>
#include<map>
#include<string>
#include<cstring>
#include<stack>
#include<deque>
#include<queue>
#include<vector>
using namespace std;
#define O2 ios::sync_with_stdio(false);cin.tie(0);cout.tie(0);
int po... | a.cc: In function 'int main()':
a.cc:64:13: error: lvalue required as left operand of assignment
64 | else if(a*b=0) cout<<"Zero";
| ~^~
|
s890766288 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main (){
int a,b,i;
i=b-a+1;
cin>>a>>b;
if(a>0){
cout<<"Positive"<<endl;
}else if(b>=0){
cout<<"Zero"<<endl;
}else if(a==0){
cout<<"Zero"<<endl;
}else if(a==b)(
cout<<"Positive"<<endl;
}else if(i%2==0){
cout<<"Positive"<<endl;
}els... | a.cc: In function 'int main()':
a.cc:15:27: error: expected ')' before ';' token
15 | cout<<"Positive"<<endl;
| ^
| )
a.cc:14:17: note: to match this '('
14 | }else if(a==b)(
| ^
a.cc: At global scope:
a.cc:16:4: error: ex... |
s249082735 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main (){
int a,b,i;
i=b-a+1;
cin>>a>>b;
if(a>0){
cout<<"Positive"<<endl;
}else if(b>=0){
cout<<"Zero"<<endl;
}else if(a==0){
cout<<"Zero"<<endl;
}else if(a==b)(
cout<<"Positive"<<endl;
}else if(i%2==0){
cout<<"Positive"<<endl;
}els... | a.cc: In function 'int main()':
a.cc:15:27: error: expected ')' before ';' token
15 | cout<<"Positive"<<endl;
| ^
| )
a.cc:14:17: note: to match this '('
14 | }else if(a==b)(
| ^
a.cc: At global scope:
a.cc:16:4: error: ex... |
s861103039 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main (){
int a,b,i;
i=b-a;
cin>>a>>b;
if(a>0){
cout<<"Positive"<<endl;
}else if(b>=0){
cout<<"0"<<endl;
}else if(a==0){
cout<<"0"<<endl;
}else if(i%2=1){
cout<<"Negative"<<endl;
}else{
cout<<"Positive"<<endl;
}
return 0;
} | a.cc: In function 'int main()':
a.cc:14:13: error: lvalue required as left operand of assignment
14 | }else if(i%2=1){
| ~^~
|
s992711629 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main (){
int a,b,i;
i=1;
cin>>a>>b;
if(a>0){
cout<<"Positive"<<endl;
}else if(b>=0){
cout<<"0"<<endl;
}else if(a==0){
cout<<"0"<<endl;
}else{
while(1){
break(a==b);
i++;
a++;
}
if(i%2==1){
cout<<"Negative"<<... | a.cc: In function 'int main()':
a.cc:16:12: error: expected ';' before '(' token
16 | break(a==b);
| ^
| ;
|
s877935800 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
long long int sum, k, n, j, a, b, c, h;
const int maxn = 100 + 1;
int e[maxn][maxn];
int q[maxn];
int w[maxn];
int main()
{
cin >> a >> b;
sum = 1;
if (a <= 0 and 0 <= b) {
cout << "Zero";
return 0;
}
if (a > 0) {
cout <<"Positive";
return 0;
}
else{
for(... | a.cc: In function 'int main()':
a.cc:29:25: error: 'retunr' was not declared in this scope
29 | retunr 0;
| ^~~~~~
|
s511337937 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
long long int sum, k, n, j, a, b, c, h;
const int maxn = 100 + 1;
int e[maxn][maxn];
int q[maxn];
int w[maxn];
int main()
{
cin >> a >> b;
sum = 1;
if (a <= 0 and 0 <= b) {
cout << "Zero";
return 0;
}
if (a > 0) {
cout <<"Positive";
return 0;
}
else{
for(... | a.cc: In function 'int main()':
a.cc:29:25: error: 'retunr' was not declared in this scope
29 | retunr 0;
| ^~~~~~
|
s049598715 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int a,b;
int main(){
cin>>a>>b;
if(a*b<=0) cout<<"Zero";
else if(a>0) cout<<"#include<bits/stdc++.h>
using namespace std;
int a,b;
int main(){
cin>>a>>b;
if((a>=0&&b<=0)||(a<=0&&b>=0)) cout<<"Zero";
else if(a>0&&b>0) cout<<"Positive";
else{
if(abs(a-b)%2==0) cout<<"... | a.cc:7:28: warning: missing terminating " character
7 | else if(a>0) cout<<"#include<bits/stdc++.h>
| ^
a.cc:7:28: error: missing terminating " character
7 | else if(a>0) cout<<"#include<bits/stdc++.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~
a... |
s600849521 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int a , b , ans = 1;
int main()
{
cin >> a >> b;
for(a ; a <= b ; a++){
ans *= a;
}
}
if (ans > 0){
cout << "Positive";
}
else if(ans < 0){
cout << "Negative";
}
else if (ans = 0){
cout << "Zero";
}
}
| a.cc:15:9: error: expected unqualified-id before 'if'
15 | if (ans > 0){
| ^~
a.cc:18:9: error: expected unqualified-id before 'else'
18 | else if(ans < 0){
| ^~~~
a.cc:21:9: error: expected unqualified-id before 'else'
21 | else if (ans = 0){
| ... |
s774917144 | p04033 | C++ | #include"bits/stdc++.h"
using namespace std;
int a,b;
int main()
{
cin>>a>>b;
if(a>0)
{
cout<<"Positive";
}
else
{
if(a==0 || (a<0&&b>0))
{
cout<<"Zero";
}
else
{
if( (abs(b)-abs(a))%2! = 0)
{
cout<<"Positive";
}
else
cout<<"Negative";
}
}
... | a.cc: In function 'int main()':
a.cc:19:46: error: expected ')' before '!' token
19 | if( (abs(b)-abs(a))%2! = 0)
| ~ ^
| )
|
s140575161 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
long long a,b;
int mian()
{
cin>>a>>b;
if(a*b>0) cout<<"Positive"<<endl;
if(a*b<0) cout<<"Negative"<<endl;
if(a*b==0) cout<<"Zero"<<endl;
return 0;
} | /usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
|
s830596222 | p04033 | C++ | {.optimization:speed, checks:off.}
#{{{ header
import algorithm, sequtils, tables, macros, math, sets, strutils, streams
when defined(MYDEBUG):
import header
proc scanf(formatstr: cstring){.header: "<stdio.h>", varargs.}
proc getchar(): char {.header: "<stdio.h>", varargs.}
proc nextInt(base:int = 0): int =
scanf(... | a.cc:2:2: error: invalid preprocessing directive #{
2 | #{{{ header
| ^
a.cc:19:10: error: stray '`' in program
19 | template `max=`*(x,y:typed):void = x = max(x,y)
| ^
a.cc:19:15: error: stray '`' in program
19 | template `max=`*(x,y:typed):void = x = max(x,y)
| ^
a.... |
s596456305 | p04033 | C++ | #include <bits/stdc++.h>
#define pb push_back
#define F first
#define S second
#define all(x) x.begin(), x.end()
using namespace std;
typedef long long ll ;
typedef long double ld ;
typedef pair<ll , ll> pll ;
const ll N = 2e5 + 30 , Mod = 1e9 + 7 ;
const ll SQ = 330 ;
int main () {
ios::sync_with_stdio(0), cin.... | a.cc: In function 'int main()':
a.cc:22:18: error: expected primary-expression before 'return'
22 | else cout << return cout << "Positive" , 0 ;
| ^~~~~~
|
s037577286 | p04033 | C | #include<stdio.h>
int main(void)
{
int a,b;
scanf("%d%d",&a,&b);
int ans=1;
for(int i=a,i<b+1;i++){
ans*=i;
}
if(ans>0){
puts("Positive");
} else if(ans==0){
puts("Zero");
} else{
puts("Negative");
}
return 0;
} | main.c: In function 'main':
main.c:7:16: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
7 | for(int i=a,i<b+1;i++){
| ^
main.c:7:24: error: expected ';' before ')' token
7 | for(int i=a,i<b+1;i++){
| ^
| ... |
s322563208 | p04033 | C++ | #include"bits/stdc++.h"
using namespace std;
int a,b;
int main()
{
cin>>a>>b;
}
{
if(a>0)cout<<"Positive"<<endl;
else if(a==0||(a<0&&b>0))cout<<"Zero"<<endl;
else if((abs(b)-abs(a))%2!=0)cout<<"Positive"<<endl;
else cout<<"Negative"<<endl;
return 0;
} | a.cc:8:5: error: expected unqualified-id before '{' token
8 | {
| ^
|
s519548148 | p04033 | C++ | #include<iostream>
using namespace std;
int main() {
int a,b,h=1;
cin>>a>>b;
for(int i=a;i<=b;i++){
h*=i;
}
if(num>0)
cout<<"Positive";
else if(num<0)
cout<<"Negative";
else
cout<<"Zero";
return 0;
} | a.cc: In function 'int main()':
a.cc:9:8: error: 'num' was not declared in this scope; did you mean 'enum'?
9 | if(num>0)
| ^~~
| enum
|
s913953849 | p04033 | C++ | #include<iostream>
using namespace std;
int main() {
int a,b,h=1;
cin>>a>>b;
for(int i=a;i<=b;i++){
h*=i;
}
if(num>0)
cout<<"Positive";
else if(num<0)
cout<<"Negative";
else
cout<<"Zero";
return 0;
} | a.cc: In function 'int main()':
a.cc:9:8: error: 'num' was not declared in this scope; did you mean 'enum'?
9 | if(num>0)
| ^~~
| enum
|
s846017588 | p04033 | C++ | #include<cstdio>
using namespace std;
long long a,b;
int main()
{
cin>>a>>b;
if(a>0)puts("Positive");
else if(b>=0)puts("Zero");
else if((a&1)^(b&1))puts("Positive");
else puts("Negative");
return 0;
} | a.cc: In function 'int main()':
a.cc:6:5: error: 'cin' was not declared in this scope
6 | cin>>a>>b;
| ^~~
a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
1 | #include<cstdio>
+++ |+#include <iostream>
2 | using namespace... |
s030548850 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std ;
template < class R > inline void Readin( R &K ) {
K = 0 ; bool F = false ; char C = getchar() ; while( C < '0' or C > '9' ) { if( C == '-' ) F = true ; C = getchar() ; }
while( C <= '9' and C >= '0' ) K = ( K << 1 ) + ( K << 3 ) + C - '0' , C = getchar() ; if( F ) K = -K... | a.cc: In function 'int Pow(int, int)':
a.cc:20:22: warning: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
20 | register int Ans = 1 ;
| ^~~
a.cc: In function 'void C_Init()':
a.cc:30:9: error: 'N' was not declared in this scope
30 | N = MaxN - ... |
s874691099 | p04033 | Java | import java.util.Scanner;
public class Tutorial011 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
if(a<=0&&0<=b) {
System.out.println("Zero");
System.exit(0);
}else if(0<=a) {
System.out.println("Positive");
}else... | Main.java:3: error: class Tutorial011 is public, should be declared in a file named Tutorial011.java
public class Tutorial011 {
^
1 error
|
s120871160 | p04033 | Java | import java.util.Scanner;
import javax.print.attribute.standard.PrinterIsAcceptingJobs;
public class Tutorial011 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
//int[] a = new int[200];
//int count=0;
if(a<=0&&0<=b) {
Syst... | Main.java:5: error: class Tutorial011 is public, should be declared in a file named Tutorial011.java
public class Tutorial011 {
^
1 error
|
s959397892 | p04033 | C++ | #include "ccc.hpp"
string solve() {
int a, b;
cin >> a >> b;
if (a <= 0 && b >= 0) return "Zero";
if (a > 0) return "Positive";
a = -a; b = -b;
if ((b - a) % 2 == 0) return "Negative";
else return "Positive";
}
int main() {
out(solve());
}
| a.cc:1:10: fatal error: ccc.hpp: No such file or directory
1 | #include "ccc.hpp"
| ^~~~~~~~~
compilation terminated.
|
s702952430 | p04033 | C++ | #include <iostream>
#include <math.h>
#include <fstream>
#include <algorithm>
#include <string>
#include <string.h>
#include <queue>
#include <vector>
#include <set>
#include <map>
using namespace std;
int main() {
int a, b;
cin >> a >> b;
if (b>0&&b - a > b) {
cout << "Zero";
return 0;
}
if (a > 0) {
cout ... | a.cc: In function 'int main()':
a.cc:24:49: error: expected '}' at end of input
24 | if ((b - a) % 2 == 0)cout << "Negative";
| ^
a.cc:13:12: note: to match this '{'
13 | int main() {
| ^
|
s303659226 | p04033 | C++ | #include<iostream>
using namespace std;
int main()
{
int a,b
if((a>0&&b<0)||(a<0&&b>0))cout<<"Zero";
else if(a>0&&b>0)cout<<"Nagative";
else cout<<"Positive";
} | a.cc: In function 'int main()':
a.cc:6:5: error: expected initializer before 'if'
6 | if((a>0&&b<0)||(a<0&&b>0))cout<<"Zero";
| ^~
a.cc:7:5: error: 'else' without a previous 'if'
7 | else if(a>0&&b>0)cout<<"Nagative";
| ^~~~
a.cc:7:18: error: 'b' was not declared in this scope
7 ... |
s023715911 | p04033 | C++ | using namespace std;
int main()
{
int a,b,c=1;
cin>>a>>b;
for(int i=a;i<=b;i++)
{
if(i<0)
c=c*-1;
if(i==0)
cout<<"Zero"<<endl;
}
if(c>0)
cout<<"Positive"<<endl;
if(c<0)
cout<<"Negative"<<endl;
if(c==0)
cout<<"Zero"<<endl;
return 0;
... | a.cc: In function 'int main()':
a.cc:5:9: error: 'cin' was not declared in this scope
5 | cin>>a>>b;
| ^~~
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 std;
a.cc:11... |
s418132397 | p04033 | C++ | #include <bits/stdc++.h>
int main()
{
int a,b;
cin>>a>>b;
if(a>0&&b>0)cout<<"Positive";
else if(a<0&&b<0)cout<<"Negative";
else cout<<"Zero";
} | a.cc: In function 'int main()':
a.cc:5:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
5 | cin>>a>>b;
| ^~~
| std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
from a.cc:1:
/usr/include/c++/14/iostream... |
s739063066 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
long long int a,b;
cin>>a>>b;
if(a>0)puts("Positive");
else if(a==0||a<0&&b>0)puts("Zero");
else if((abs(b)-abs(a))%2!=0)put("Positive");
else puts("Negative");
} | a.cc: In function 'int main()':
a.cc:8:34: error: 'put' was not declared in this scope; did you mean 'putw'?
8 | else if((abs(b)-abs(a))%2!=0)put("Positive");
| ^~~
| putw
|
s096149671 | p04033 | C++ | #include<bits/stdc++>
using namespace std;
int main()
{
int a,b;
cin>>a>>b;
if(a>0)
cout<<"Positive";
else if(a==0||(a<0&&b>0))
cout<<"Zero";
else if((abs(b)-abs(a))%2!=0)
cout<<"Positive";
else
cout<<"Negative";
return 0;
} | a.cc:1:9: fatal error: bits/stdc++: No such file or directory
1 | #include<bits/stdc++>
| ^~~~~~~~~~~~~
compilation terminated.
|
s610108869 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
int a,b;
int c=0;
cin>>a>>b;
for(int i=0;i>a;i--)
c++;
if(a<=0&&0<=b)
cout<<"Zero"
else if(b<0&&c%2==1)
cout<<"Negative";
else
cout<<"Positive";
} | a.cc: In function 'int main()':
a.cc:11:29: error: expected ';' before 'else'
11 | cout<<"Zero"
| ^
| ;
12 | else if(b<0&&c%2==1)
| ~~~~
|
s485769959 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
int a,b;
int c=0;
cin>>a>>b;
for(int i=0;i>a;i--)
c++;
if(a<=0&&0<=b)
cout<<"Zero"
else if(b<0&&c%2==1)
cout<<"Negative";
else
cout<<"Positive";
} | a.cc: In function 'int main()':
a.cc:11:29: error: expected ';' before 'else'
11 | cout<<"Zero"
| ^
| ;
12 | else if(b<0&&c%2==1)
| ~~~~
|
s352592364 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
int a,b;
int c=0;
cin>>a>>b;
for(int i=0;i>a;i--)
c++;
if(a<=0&&0<=b)
cout<<"zero"
else if(b<0&&c%2==1)
cout<<"Negative";
else
cout<<"Positive";
} | a.cc: In function 'int main()':
a.cc:11:29: error: expected ';' before 'else'
11 | cout<<"zero"
| ^
| ;
12 | else if(b<0&&c%2==1)
| ~~~~
|
s916577593 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int main() {
int a,b;
int c=0;
cin>>a>>b;
for(int i=0;i>a;i--)
c++;
if(a=<0&&0=<b)
cout<<"zero"
else if(b<0&&c%2==1)
cout<<"Negative"
else
cout<<"Positive"
} | a.cc: In function 'int main()':
a.cc:10:22: error: expected primary-expression before '<' token
10 | if(a=<0&&0=<b)
| ^
a.cc:10:28: error: expected primary-expression before '<' token
10 | if(a=<0&&0=<b)
| ^
a.cc:11:29: er... |
s398089993 | p04033 | C++ | #include<iostream>
#include<cmath>
#include<cstdio>
#include<cstring>
using namespace std;
int main()
{
int a,b;
cin>>a>>b;
int mls=abs(b)-abs(a)%2;
if(a>0) cout<<"Positive";
else if(a==0||(a<0&&b>0)) cout<<"Zero";
else if(c!=0) cout<<"Positive";
else cout<<"Negative";
return 0;
} | a.cc: In function 'int main()':
a.cc:13:13: error: 'c' was not declared in this scope
13 | else if(c!=0) cout<<"Positive";
| ^
|
s624376530 | p04033 | C++ | #include<iostream>
uisng namespace std;
int main()
{
long long a,b;
cin>>a>>b;
if((a>0&&b>0)||(a<0&&b<0)) cout<<"Positive";
if((a>0&&b<0)||(a<0&&b>0)) cout<<"Negative";
if((a==0&&b==0)||a==0||b==0)) cout<<"Zero";
return 0;
} | a.cc:2:1: error: 'uisng' does not name a type
2 | uisng namespace std;
| ^~~~~
a.cc: In function 'int main()':
a.cc:6:5: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
6 | cin>>a>>b;
| ^~~
| std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:... |
s327768039 | p04033 | C++ | #define _CRT_SECURE_NO_WARNINGS
#include<bits/stdc++.h>
using namespace std;
#ifndef FAST_IO
#define IOS ios_base::sync_with_stdio(false);cin.tie(nullptr);
#endif
#define FILE_IO freopen("input.txt","r",stdin)
#define int long long
#define f first
#define s second
#define endl '\n'
#define all(c) c.begin(),c.end()
#d... | a.cc: In function 'void solve()':
a.cc:38:29: error: expected primary-expression before '<' token
38 | else if ( b >= 0 && a =< 0) ret = "Zero";
| ^
|
s978486425 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(){
int A,B,ans,a,b,c;
cin>>A>>B;
ans=0;
if(A<=0&&B>=0){
cout<<Zero<<endl;
return 0;
}
else{
if(A>0){
cout<<"Positive"<<endl;
return 0;
}
else{
if((B-A)%2==1){
cout<<"Positive"<<endl;
return 0;
}
... | a.cc: In function 'int main()':
a.cc:9:11: error: 'Zero' was not declared in this scope
9 | cout<<Zero<<endl;
| ^~~~
|
s241341852 | p04033 | C++ | #include <iostream>
#include <vector>
#include <algorithm>
#include <set>
#include <map>
#include <utility>
#include <tuple>
#include <string>
using namespace std;
#define rep(i, n) for(int i = 0; i < (int)(n); i++)
#define SORT(x) sort(x.begin(),x.end())
#define REVE(x) reverse(x.begin(),x.end())
#define all(x) (x).be... | a.cc: In function 'int main()':
a.cc:33:44: error: no match for 'operator=' (operand types are 'std::basic_ostream<char>' and 'const char*')
33 | cout << A=0? "Zero" :A > 0?"Positive":"Negative";
| ^~~~~~~~~~
In file included from /usr/include/c++/14/iostream:41,... |
s148842434 | p04033 | C++ | #include <iostream>
#include <vector>
#include <string>
#include <cmath>
#include <set>
#include <algorithm>
#include <array>
#include <complex>
#include <string>
#include <utility>
#include <map>
#include <queue>
#include <list>
#include <functional>
#include <numeric>
#include <stack>
#include <tuple>
using namespac... | a.cc: In function 'int main()':
a.cc:41:18: warning: division by zero [-Wdiv-by-zero]
41 | if(temp/2%=0){
| ~~~~~~^~~
a.cc:41:16: error: lvalue required as left operand of assignment
41 | if(temp/2%=0){
| ~~~~^~
|
s802831054 | p04033 | C++ | #include <iostream>
#include <cmath>
#include <algoruthm>
using namespace std;
int main(void){
int a,b;
cin >> a >> b;
if(a <= 0 && b >= 0)
cout << "Zero" << endl;
else if(a < 0 && b < 0){
if(abs(b - a) % 2 == 0)
cout << "Negative" << endl;
else
cout << "Positive" << endl;
}
else
... | a.cc:3:10: fatal error: algoruthm: No such file or directory
3 | #include <algoruthm>
| ^~~~~~~~~~~
compilation terminated.
|
s384030768 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
#define IL inline
#define rep(i,j,k) for(int i=j;i<=k;++i)
#define repd(i,j,k) for(int i=j;i>=k;--i)
#define pb push_back
#define db double
#define mp make_pair
#define mp3(a,b,c) mp(mp(a,b),c)
#define pii pair<int,int>
#define piii pair<pii,int>
#define fr first
#define se ... | a.cc: In function 'int main()':
a.cc:39:15: error: 'mib' was not declared in this scope
39 | int l=mib(b,0);
| ^~~
|
s273308808 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int a,b;
int main()
{
cin>>a>>b;
if(a>0)cout<<"Positive";
else if(b>=0)cout<<"Zero";
else if((abs(b)-abs(a))%2==1)cout<<"Positive";
else cout<<"Negative";
cout<<endl;
return 0;)
} | a.cc: In function 'int main()':
a.cc:12:10: error: expected primary-expression before ')' token
12 | return 0;)
| ^
|
s266077321 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main()
{
int a,b;
cni>>a>>b;
if(a*b>0) cout<<"Positive"<<endl;
else if(a*b<0) cout<<"Negative"<<endl;
else cout<<"Zero"<<endl;
return 0;
} | a.cc: In function 'int main()':
a.cc:6:9: error: 'cni' was not declared in this scope
6 | cni>>a>>b;
| ^~~
|
s221819822 | p04033 | C++ | #include<iostream>
using namespace std;
int main(){
int a,b,c;
cin >> a >> b;
if(a <= 0 && 0 <= b){
cout << "Zero";
return 0;
}
else if(0 < a){
cout << "Positive";
return 0;
}
c = b - a + 1
else if(c % 2 == 0){
cout << "Negative";
return 0;
}
}
| a.cc: In function 'int main()':
a.cc:14:14: error: expected ';' before 'else'
14 | c = b - a + 1
| ^
| ;
15 | else if(c % 2 == 0){
| ~~~~
|
s420278145 | p04033 | C++ | #include<iostream>
using namespace std;
int main(){
int a,b,c;
cin >> a >> b;
if(a <= 0 && 0 <= b){
cout << Zero;
return 0;
}
else if(0 < a){
cout << Positive;
return 0;
}
c = b - a + 1
else if(c % 2 == 0){
cout << Negative;
return 0;
}
}
| a.cc: In function 'int main()':
a.cc:7:13: error: 'Zero' was not declared in this scope
7 | cout << Zero;
| ^~~~
a.cc:11:13: error: 'Positive' was not declared in this scope
11 | cout << Positive;
| ^~~~~~~~
a.cc:14:14: error: expected ';' before 'else'
14 | c = b -... |
s611735925 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(void)
{
int a,b;
cin>>a>>b;
if(0<a&&a<=b)
cout<<"Positive"<<endl;
else if(a<=b&&b<0){
if((b-a+1)%2==0)
cout<<"Positive"<<endl;
else
cout<<"Negative"<<endl;
}
else if(a<=0&&0<=b)
cuot<<"Zero"<<endl;
} | a.cc: In function 'int main()':
a.cc:17:5: error: 'cuot' was not declared in this scope
17 | cuot<<"Zero"<<endl;
| ^~~~
|
s365033664 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(void)
{
int a,b;
cin>>a>>b;
if(a>=0&&0<=b)
cout<<"Zero"<<endl;
else if(a>0)
cout<<"Positive"<<endl;
else
cuot<<"Negative"<<endl;
} | a.cc: In function 'int main()':
a.cc:13:5: error: 'cuot' was not declared in this scope
13 | cuot<<"Negative"<<endl;
| ^~~~
|
s114591067 | p04033 | C++ | #include<bits/stdc++.h>
using namespace std;
int main(void)
{
int a,b;
cin>>a>>b;
if(a>=0%%0<=b)
cout<<"Zero"<<endl;
else if(a>0)
cout<<"Positive"<<endl;
else
cuot<<"Negative"<<endl;
} | a.cc: In function 'int main()':
a.cc:8:11: error: expected primary-expression before '%' token
8 | if(a>=0%%0<=b)
| ^
a.cc:13:5: error: 'cuot' was not declared in this scope
13 | cuot<<"Negative"<<endl;
| ^~~~
|
s635843430 | p04033 | C | #include<stdio.h>
int main(){
int a,b,mul,i;
scanf("%d %d",&a,&b);
mul = 1;
if(a>0){
printf("Positive");
}
else if(a==0){
printf("Zero");
}
else if(b>=0){
printf("Zero";)
}
else{
if(b-a+1%2==0){
printf("Positive");
}
else{
printf("Negative");
}
}
r... | main.c: In function 'main':
main.c:19:18: error: expected ')' before ';' token
19 | printf("Zero";)
| ~ ^
| )
main.c:19:20: error: expected ';' before '}' token
19 | printf("Zero";)
| ^
| ;
20 | }
| ... |
s203053320 | p04033 | C++ | #include <bits/stdc++.h>
using namespace std;
int main(){
int A,B;
cin>>A>>B;
if(A<0){
if(B>=0){
cout<<"Zero"<<endl;
}
if(A==B){
cout<<"Negative"<<endl;
}
if(A!=B&&B<0){
if(B+A%2==0){
cout<<"Negative"<<endl;
}
else
cout<<"Positive"<<endl;
... | a.cc:23:1: error: expected unqualified-id before 'if'
23 | if(A==0){
| ^~
a.cc:26:7: error: expected unqualified-id before 'if'
26 | if(A>0){
| ^~
a.cc:29:5: error: expected declaration before '}' token
29 | }
| ^
|
s029156021 | p04033 | C++ | #include<iostream>
using namespace std;
int main()
{
long long a,b;
cin>>a>>b;
if(a > 0) cout<<"Positive";
if(a < 0 && b < 0) cout<<"Negative";
if(a == 0 || a < 0 && b > 0) cout<<"Zero"
return 0;
} | a.cc: In function 'int main()':
a.cc:9:46: error: expected ';' before 'return'
9 | if(a == 0 || a < 0 && b > 0) cout<<"Zero"
| ^
| ;
10 | return 0;
| ~~~~~~
|
s775484283 | p04033 | C++ | //hi | /usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
|
s058057156 | p04033 | C++ | a,b=int(input().split())
if b < 0:
if (b-a+1) % 2 == 0:
ans = 'Positive'
elif (b-a+1) % 2 == 1:
ans = 'Negative'
elif a > 0:
ans='Positive'
else
ans='Zeros'
print(ans) | a.cc:4:15: warning: multi-character literal with 8 characters exceeds 'int' size of 4 bytes
4 | ans = 'Positive'
| ^~~~~~~~~~
a.cc:6:15: warning: multi-character literal with 8 characters exceeds 'int' size of 4 bytes
6 | ans = 'Negative'
| ^~~~~~~~~~
a.cc... |
s392986974 | p04033 | C++ | #include <bits/stdc++.h>
#define F first
#define S second
#define all(a) a.begin(),a.end()
#define setDP(arr) memset(arr,-1,sizeof arr)
#define Clear(arr) memset(arr,0,sizeof arr)
#define oo 2000000000
#define inf 1000000000000000000
#define P1 31
#define P2 37
#define M 1000000007
#define M2 1000000009
#define pii pa... | a.cc: In function 'int main()':
a.cc:41:18: error: 'i' was not declared in this scope
41 | cout <<solve(i,j) << endl;
| ^
a.cc:41:20: error: 'j' was not declared in this scope; did you mean 'jn'?
41 | cout <<solve(i,j) << endl;
| ^
| ... |
s877482402 | p04033 | C++ | #include <bits/stdc++.h>
#define F first
#define S second
#define all(a) a.begin(),a.end()
#define setDP(arr) memset(arr,-1,sizeof arr)
#define Clear(arr) memset(arr,0,sizeof arr)
#define oo 2000000000
#define inf 1000000000000000000
#define P1 31
#define P2 37
#define M 1000000007
#define M2 1000000009
#define pii pa... | a.cc: In function 'int main()':
a.cc:41:18: error: 'i' was not declared in this scope
41 | cout <<solve(i,j) << endl;
| ^
a.cc:41:20: error: 'j' was not declared in this scope; did you mean 'jn'?
41 | cout <<solve(i,j) << endl;
| ^
| ... |
s804533403 | p04033 | C++ | #include<iostream>
using namespace std;
int main(){
int a,b;
cin >> a >> b;
if(a>0)cout << "Positive" << endl;
else if(a<=0 && b>=0) << "Zero" << endl;
else{
if((a-b)%2==0)cout<<"Negative" << endl;
else cout << "Positive" << endl;
}
} | a.cc: In function 'int main()':
a.cc:8:31: error: expected primary-expression before '<<' token
8 | else if(a<=0 && b>=0) << "Zero" << endl;
| ^~
|
s617423120 | p04033 | C++ | #include<iostream>
using namespace std;
int main(){
int a,b;
cin >> a >> b;
if(a>0)cout << "Positive" << endl;
else if(a<=0 && b>=0)cout << "Zero" << endl;
else{
if((a-b)%2==0)cout<<"Negative" << endl;
else cout << "Positive" << endl
}
} | a.cc: In function 'int main()':
a.cc:11:40: error: expected ';' before '}' token
11 | else cout << "Positive" << endl
| ^
| ;
12 | }
| ~
|
s154629449 | p04033 | C++ | #include<iostream>
using namespace std;
int main(){
int a,b;
cin >> a >> b;
if(a>0)cout << "Positive" << endl;
else if(a<=0 && b>=0) << "Zero" << endl;
else{
if((a-b)%2==0)cout<<"Negative" << endl;
else cout << "Positive" << endl
}
} | a.cc: In function 'int main()':
a.cc:8:31: error: expected primary-expression before '<<' token
8 | else if(a<=0 && b>=0) << "Zero" << endl;
| ^~
a.cc:11:40: error: expected ';' before '}' token
11 | else cout << "Positive" << endl
| ... |
s928227895 | p04033 | C++ | include<bits/stdc++.h>
using namespace std;
int main()
{
int a,b,ju;
cin>>a>>b;
ju=b-a+1;//数字个数
if(a>0)
{
cout<<"Positive"<<endl;
return 0;
}
if(a<0&&b<0&&ju%2==1)//刚开始没想到负负得正,WA了多次
{
cout<<"Negative"<<endl;
return 0;
}
if(a<=0&&b>=0)
{
... | a.cc:1:1: error: 'include' does not name a type
1 | include<bits/stdc++.h>
| ^~~~~~~
a.cc: In function 'int main()':
a.cc:7:5: error: 'cin' was not declared in this scope
7 | cin>>a>>b;
| ^~~
a.cc:11:9: error: 'cout' was not declared in this scope
11 | cout<<"Positive"<<endl;
... |
s148699830 | p04033 | C++ | #include<cstdio>
#include <bits/stdc++.h>
using namespace std;
int a,b;
int main(){
scanf("%d%d",&a,&b);
if(a>0)puts("Positive");
else if(b>=0)puts("Zero")
else if((a&1)^(b&1))puts("Positive");
else puts("Negative");
return 0;
} | a.cc: In function 'int main()':
a.cc:8:30: error: expected ';' before 'else'
8 | else if(b>=0)puts("Zero")
| ^
| ;
9 | else if((a&1)^(b&1))puts("Positive");
| ~~~~
|
s172092250 | p04033 | C++ | #include<cstdio>
using namespace std;
int a,b;
int main(){
scanf("%d%d",&a,&b);
if(a>0)puts("Positive");
else if(b>=0)puts("Zero")
else if((a&1)^(b&1))puts("Positive");
else puts("Negative");
return 0;
} | a.cc: In function 'int main()':
a.cc:7:30: error: expected ';' before 'else'
7 | else if(b>=0)puts("Zero")
| ^
| ;
8 | else if((a&1)^(b&1))puts("Positive");
| ~~~~
|
s371699907 | p04033 | C++ | #include <iostream>
using namespace std;
int main(){
long long int i,j;
cin>>i>>j;
if(i>0&&j>0){
cout<<"Positive" ;return 0;
}
if(i==0||j==0){
cout<<"Zero";return 0;
}
if(i>0&&j<0){
cout<<"Zero";return 0;
}
if(i<0&&j>0){
cout<<"Zero";return 0;
}
... | a.cc: In function 'int main()':
a.cc:18:30: error: expected ';' before 'int'
18 | if(j==i) cout<<"Negative"
| ^
| ;
19 | int k=j-i;
| ~~~
a.cc:20:8: error: 'k' was not declared in this scope
20 | ... |
s897415189 | p04033 | C++ | #include<iostream>
#include<cmath>
#include<numeric>
#include<string>
#include<algorithm>
#include<vector>
#include<map>
#define rep(i,n) for(int i=0;i<n;i++)
#define rep1(i,n) for(int i=1;i<n;i++)
#define int64 long long
#define modbig (10*10*10*10*10*10*10*10*10+7)
using namespace std;
int main(){
int a,b;
cin>>... | a.cc: In function 'int main()':
a.cc:18:9: error: no match for 'operator<' (operand types are 'std::ostream' {aka 'std::basic_ostream<char>'} and 'const char [5]')
18 | cout<"Zero";
| ~~~~^~~~~~~
| | |
| | const char [5]
| std::ostream {aka std::basic_ostream<char>}
... |
s609822212 | p04033 | C++ | #include <iostream>
int main(void) {
int a, b;
std::cin >> a >> b;
if(a <= 0 && b >= 0) std::cout << 'Zero' <<std::endl;
if(a > 0 && b > 0) std::cout << 'Positive' <<std::endl;
if(a < 0 && b < 0 && (b - a + 1) % 2 + 1) {
std::cout << 'Positive' <<std::endl;
} else {
std::cout << 'Negative' <<std... | a.cc:7:37: warning: multi-character character constant [-Wmultichar]
7 | if(a <= 0 && b >= 0) std::cout << 'Zero' <<std::endl;
| ^~~~~~
a.cc:8:35: warning: multi-character literal with 8 characters exceeds 'int' size of 4 bytes
8 | if(a > 0 && b > 0) std::cout << 'P... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.