Problem:


Problem Statement

You are given two integers a and b (a≤b). Determine if the product of the integers a, a+1, …, b is positive, negative or zero.

Constraints

a and b are integers.

-10^9≤a≤b≤10^9

Partial Score

In test cases worth 100 points, -10≤a≤b≤10.

Input

The input is given from Standard Input in the following format:

a b

Output

If the product is positive, print Positive. If it is negative, print Negative. If it is zero, print Zero.

Sample Input 1

1 3

Sample Output 1

Positive

1×2×3=6 is positive.

Sample Input 2

-3 -1

Sample Output 2

Negative

(-3)×(-2)×(-1)=-6 is negative.

Sample Input 3

-1 1

Sample Output 3

Zero

(-1)×0×1=0.



Sample input:
1 3


Sample output:
Positive

Submission status: Accepted

Solution code:

a,b = map(int,input().split())

if a > 0:
    print ("Positive")

elif a*b <= 0:
    print ("Zero")

else:

    if (b-a) % 2 == 1:
        print ("Positive")
    else:
        print ("Negative")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a <= 0 and 0 <= b:
    print('Zero')
elif 0 < a:
    print('Positive')
else:
    if (b - a) %  2 == 0:
        print('Negative')
    else:
        print('Positive')

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a <= 0 <= b:
    ans = 'Zero'
elif 0 < a or b < 0 and (b - a) % 2 == 1:
    ans = 'Positive'
else:
    ans = 'Negative'
print(ans)

Submission status: Accepted

Solution code:
a,b = map(int,input().split())

if((a<=0 and b>=0)):
    print("Zero")
elif(a<0 and b<0):
    if(abs(a-b)%2==0):
        print("Negative")
    else:
        print("Positive")
elif(a>0 and b>0):
    print("Positive")
else:
    if(abs(a)%2==0):
        print("Positive")
    else:
        print("Negative")

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a <= 0 and b >=0:
         print("Zero")
elif a < 0 and (a-b)%2 == 0:
         print("Negative")
else:
         print("Positive")

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
x = b-a
if a<=0 and b>=0:
    print("Zero")
elif b<0:
    if x%2==0:
        print("Negative")
    else:
        print("Positive")
else:
    print("Positive")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a <= 0 <= b:
    print('Zero')
elif 0 < a:
    print('Positive')
else:
    if (b - a + 1) % 2 == 0:
        print('Positive')
    else:
        print('Negative')

Submission status: Accepted

Solution code:
a, b = map(int,input().split())

if a * b <= 0:
    print("Zero")
elif a > 0 and b > 0:
    print("Positive")
else:
    A = ["Positive", "Negative"]
    print(A[(b-a+1)%2])

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a > 0:
    print('Positive')
else:
    if b < 0:
        if ((-1*a)-(-1*b)+1)%2 == 0:
            print('Positive')
        else:
            print('Negative')
    else:
        print('Zero')

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- Coding: utf-8 -*-

import sys


input = sys.stdin.readline


def main():
    a, b = map(int, input().split())
    if a <= 0 and b >= 0:
        print('Zero')
        sys.exit(0)
    elif b < 0 and (b-a) % 2 == 0:
        print('Negative')
    else:
        print('Positive')


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import sys

a, b = map(int, input().split())
cnt = 0
if a <= 0 and 0 < b:
    print('Zero')
    sys.exit()

if b <= 0:
    cnt = abs(a - b) + 1

ans = ''
if cnt % 2 == 0:
    ans = 'Positive'
else:
    ans = 'Negative'

print(ans)

Submission status: Accepted

Solution code:
import sys
a,b = map(int,input().split())
if a > 0:
    print('Positive')
    sys.exit()
if b >= 0:
    print('Zero')
    sys.exit()
if (b-a+1)%2 == 1:
    print('Negative')
else:
    print('Positive')

Submission status: Accepted

Solution code:
def slove():
    import sys
    input = sys.stdin.readline
    a, b = list(map(int, input().rstrip('\n').split()))
    if a * b <= 0:
        print("Zero")
    elif a > 0 and b > 0:
        print("Positive")
    else:
        if a * b >= 0:
            if abs(a - b + 1) % 2 == 0:
                print("Positive")
            else:
                print("Negative")
        else:
            if abs(a) % 2 == 0:
                print("Positive")
            else:
                print("Negative")


if __name__ == '__main__':
    slove()

Submission status: Accepted

Solution code:
A, B = map(int, input().split())

if A <= 0 and B >= 0:
    print('Zero')
elif A > 0:
    print('Positive')
else:
    if (B - A + 1) % 2 == 0:
        print('Positive')
    else:
        print('Negative')

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a>0:
    ans='Positive'
elif a<=0<=b:
    ans='Zero'
else:
    ans=('Positive' if (b-a+1)%2==0 else 'Negative')
print(ans)

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
n=b-a+1
if a<=0 and b>=0:
    print("Zero")
elif a<0:
    if n%2==0:
        print("Positive")
    else:
        print("Negative")
elif b>0:
    print("Positive")

Submission status: Accepted

Solution code:
import sys,os,random
a,b=map(int,input().split())
if a<=0<=b:print("Zero")
elif max(0,min(0,b)-a+1)&1:print("Negative")
else:print("Positive")

Submission status: Accepted

Solution code:
a,b = map(int,input().split())	
ans=["Positive", "Negative", "Zero"]
if a > 0:
    print(ans[0])
elif a<=0 and b>=0:
    print(ans[2])
elif (b-a)%2 == 0:
    print(ans[1])
else:
    print(ans[0])

Submission status: Accepted

Solution code:
a, b = input().split()
a, b = [int(a), int(b)]

if b < 0:
    if (b - a + 1) % 2 == 0:
        result = 'Positive'
    else:
        result = 'Negative'
elif 0 < a:
    result = 'Positive'
else:
    result = 'Zero'

print(result)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if 0 < a:
    print("Positive")
elif a <= 0 <= b:
    print("Zero")
else:
    if (b - (a - 1)) % 2 == 0:
        print("Positive")
    else:
        print("Negative")

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a <= 0 and b >= 0 or a >= 0 and b <= 0 or a == 0 or b == 0:
  print("Zero")
elif a > 0 and b > 0 or (a+b) % 2 == 1: 
  print("Positive")
else:
  print("Negative")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a > 0:
    print("Positive")
elif b < 0:
    print("Negative" if (abs(a - b)) % 2 == 0 else "Positive")
else:
    print("Zero")

Submission status: Accepted

Solution code:
a,b = [int(i) for i in input().split()]

if a >= 0:
    print('Positive')
elif b >= 0:
    print('Zero')
elif (b -a +1)%2 == 0:
    print('Positive')
else:
    print('Negative')

Submission status: Accepted

Solution code:
a,b=map(int,input().split())

if a<0 and b<0:
    if (b-a+1)%2==1:
        print("Negative")
    else:
        print("Positive")
elif a==0 or b==0:
    print("Zero")
elif a<0 and b>0:
    print("Zero")
else:
    print("Positive")

Submission status: Accepted

Solution code:
a,b=map(int,input().split())

if a<=0<=b:
  print('Zero')
elif 0<a:
  print('Positive')
else:
  if (b-a+1)%2==1:
    print('Negative')
  else:
    print('Positive')

Submission status: Accepted

Solution code:
import sys
import os
a, b = map(int,input().split())
if a*b <= 0:
    print("Zero")
    sys.exit()
if a > 0 and b > 0:
    print("Positive")
    sys.exit()
if (b-a)%2==0:
    print("Negative")
else:
    print("Positive")

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a == 0 or b == 0 or a*b < 0:
    print('Zero')
elif a > 0:
    print('Positive')
else:
    if (b - a + 1) % 2 == 0:
        print('Positive')
    else:
        print('Negative')

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a > 0 and b > 0:
    print("Positive")
elif a <= 0 and b >= 0:
    print("Zero")
else:
    if (a - b) % 2 == 0:
        print("Negative")
    else:
        print("Positive")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a <= 0 and b >= 0:
    print('Zero')
elif a > 0:
    print('Positive')
elif b < 0:
    if (b - a + 1) % 2 == 0:
        print('Positive')
    else:
         print('Negative')

Submission status: Accepted

Solution code:
a,b=map(int,input().split())

if a>0:
  print("Positive")
elif a==0:
  print("Zero")
else:
  if b>=0:
    print("Zero")
  else:
    if (b-a)%2:
      print("Positive")
    else:
      print("Negative")

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<=0 and 0<=b:
  print("Zero")
elif b<0:
  if (b-a)%2==0:print("Negative")
  else:print("Positive")
else:
  print("Positive")

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<=0 and 0<=b:
  print("Zero")
elif a<0 and b<0:
  if (b-a)%2==0:
    print("Negative")
  else:
    print("Positive")
else:
  print("Positive")

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a<0 and b<0:
    if abs(a-b)%2==0:
        print("Negative")
    else:
        print("Positive")
elif (a<0 and b>=0) or a==0 or b==0:
    print("Zero")
else:
    print("Positive")

Submission status: Accepted

Solution code:
def slove():
    import sys
    input = sys.stdin.readline
    a, b = list(map(int, input().rstrip('\n').split()))
    if a * b > 0 :
        if a > 0 and b > 0:
            print("Positive")
        elif a < 0 and b < 0:
            print("Positive" if abs(a - b + 1) % 2 == 0 else "Negative")
        elif a < 0 and 0 < b:
            print("Positive" if abs(a) % 2 == 0 else "Negative")
    else:
        print("Zero")


if __name__ == '__main__':
    slove()

Submission status: Accepted

Solution code:
# AGC002A - Range Product
def main():
    A, B = map(int, input().split())
    if A <= 0 <= B:
        print("Zero")
    else:
        flg = 0 < A or (abs(A - B) + 1) % 2 == 0
        print("Positive" if flg else "Negative")


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
import bisect
import heapq
import itertools
import math
import operator
import os
import re
import string
import sys
from collections import Counter, deque, defaultdict
from copy import deepcopy
from decimal import Decimal
from fractions import gcd
from functools import lru_cache, reduce
from operator import itemgetter, mul, add, xor

import numpy as np

if os.getenv("LOCAL"):
    sys.stdin = open("_in.txt", "r")

sys.setrecursionlimit(2147483647)
INF = float("inf")
IINF = 10 ** 18
MOD = 10 ** 9 + 7


A, B = list(map(int, sys.stdin.readline().split()))

if A <= 0 <= B:
    print('Zero')
elif A < 0 and (min(B, 0) - A) % 2 == 0:
    print('Negative')
else:
    print('Positive')

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
ans="Positive"
if a<=0 and b>=0:
    ans="Zero"
elif a<0:
    if (a-min(0,b)+1)%2!=0:
        ans="Negative"
print(ans)

Submission status: Accepted

Solution code:
def resolve():
    a, b = map(int, input().split())
    if a < 0 and b < 0:
        print("Positive" if (b - a) % 2 else "Negative")
    elif a > 0 and b > 0:
        print("Positive")
    else:
        print("Zero")


if __name__ == "__main__":
    resolve()

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a > 0:
  print("Positive")
elif b < 0:
  if (b-a+1)%2 == 1:
    print("Negative")
  else:
    print("Positive")
else:
  print("Zero")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a <= 0 and b >= 0:
  print('Zero')
elif a > 0:
  print('Positive')
else:
  if (b - a) % 2 == 1:
    print('Positive')
  else:
    print('Negative')

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<=0<=b:print("Zero")
elif(b-a)%2==0and b<0:print("Negative")
else:print("Positive")

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<=0 and b>=0:
    print('Zero')
elif a>0 and b>0:
    print('Positive')
elif a<0 and b<0:
    if ((-a)-(-b)+1)%2==0:
        print("Positive")
    else:
        print("Negative")

Submission status: Accepted

Solution code:
def main():
    a, b = (int(i) for i in input().split())
    if a <= 0 and 0 <= b:
        print("Zero")
    elif a > 0:
        print("Positive")
    elif b < 0:
        if (b - a) % 2 == 0:
            print("Negative")
        else:
            print("Positive")
if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
a, b = list(map(int, input().split()))
if a>0 and b>0:
  print("Positive")
elif a<=0<=b:
  print("Zero")
else:
  if (b-a)%2:
    print("Positive")
  else:
    print("Negative")

Submission status: Accepted

Solution code:
def solve(a, b):
    if (a * b < 0) or (a == 0) or (b == 0):
        return "Zero"
    elif (a < 0) and ((a-b+1) % 2 == 1):
        return "Negative"
    else:
        return "Positive"

a, b = map(int, input().split())
print(solve(a, b))

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a <= 0 <= b:
  print("Zero")
elif b < 0:
  negativeCount = b - a + 1
  if negativeCount % 2 == 0:
    print("Positive")
  else:
    print("Negative")
else:
  print("Positive")

Submission status: Accepted

Solution code:
import sys
input=sys.stdin.readline

def main():
    a,b = map(int,input().split())
    if a<=0 and 0<=b:
        print("Zero")
        return
    elif a<0 and b<0:
        if (b-a)%2 == 0:
            print("Negative")
            return
    print("Positive")

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
a,b = map(int, input().split())

if a*b<=0:
    print('Zero')
elif a>0:
    print('Positive')
elif (b-a)%2==1:
    print('Positive')
else:
    print('Negative')

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a>0 and b>0:
  print('Positive')
elif a <= 0 and b >=0:
  print('Zero')
else:
  print('Positive' if (b-a +1)%2 ==0 else 'Negative')

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a <= 0 and b >= 0:
  print("Zero")
elif a > 0 and b > 0:
  print("Positive")
elif a < 0 and b < 0:
  if a == b:
    print("Positive")
  elif abs(a-b) % 2 == 1:
    print("Positive")
  elif abs(a-b) % 2 == 0:
    print("Negative")

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
#AGC2 A

import sys
import math
from bisect import bisect_right as br
from bisect import bisect_left as bl
sys.setrecursionlimit(1000000000)
from heapq import heappush, heappop,heappushpop
from collections import defaultdict
from itertools import accumulate
from collections import Counter
from collections import deque
from operator import itemgetter
from itertools import permutations
mod = 10**9 + 7
inf = float('inf')
def I(): return int(sys.stdin.readline())
def LI(): return list(map(int,sys.stdin.readline().split()))

a,b = LI()
if a == b:
    if a == 0:
        print('Zero')
    else:
        print('Positive')
elif a <= 0 and b >= 0:
    print('Zero')
elif a < 0 and b < 0:
    if (b-a)%2:
        print('Positive')
    else:
        print('Negative')
else:
    print('Positive')

Submission status: Accepted

Solution code:
a,b = map(int, input().split())

if a <= 0 <= b :
    print('Zero')
elif 0 < a:
    print('Positive')
else:
    if (b-a)%2 == 0:
        print('Negative')
    else:
        print('Positive')

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<=0<=b:
    print("Zero")
elif a>0:
    print("Positive")
else:
    if (b-a)%2==0:
        print("Negative")
    else:
        print("Positive")

Submission status: Accepted

Solution code:
a=list(map(int,input().split()))
a,b=a[0],a[1]
if a<=0 and b>=0:
    print('Zero')
elif a>0:
    print('Positive')
else:
    if (b-a)%2==0:
        print('Negative')
    else:
        print('Positive')

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
num = abs(b - a + 1)

if a <= 0 <= b:
    print('Zero')
elif a < 0 and b < 0:
    if num % 2 == 0:
        print('Positive')
    else:
        print('Negative')
else:
    print('Positive')

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if b < 0:
  if (b-a) % 2 == 0:
    print('Negative')
  else:
    print('Positive')
elif a <= 0:
  print('Zero')
else:
  print('Positive')

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

# a - b - 0 -> n or p
# a - 0 - b -> zero
# 0 - a - b -> p
def main():
    if a <= 0 <= b:
        return 'Zero'
    if 1 <= a:
        return 'Positive'
    
    c = b - a + 1
    if c % 2 == 0:
        return 'Positive'
    else:
        return 'Negative'

print(main())

Submission status: Accepted

Solution code:
a,b=map(int, input().split())

if a>0:
    print("Positive")
else:
    if b>=0:
        print("Zero")
    elif (a-b-1)%2==0:
        print("Positive")
    else:
        print("Negative")

Submission status: Accepted

Solution code:
a,b = map(int,input().split())

if a*b <= 0:
  print("Zero")
elif a > 0:
  print("Positive")
elif (b-a)%2:
  print("Positive")
else:
  print("Negative")

Submission status: Accepted

Solution code:
def slove():
    import sys
    input = sys.stdin.readline
    a, b = list(map(int, input().rstrip('\n').split()))
    if a > 0 and b > 0:
        print("Positive")
    elif a * b < 0 or a * b == 0:
        print("Zero")
    else:
        print("Negative" if (a - b + 1) % 2 != 0 else "Positive")


if __name__ == '__main__':
    slove()

Submission status: Accepted

Solution code:
def main():
    a, b = map(int, input().split())
    if a > 0: # a, b > 0
        return "Positive"
    elif b >=0 and a <=0: # a <= 0 <= b
        return "Zero"
    else: # a < 0 and b < 0
        if (b-a+1) % 2 == 0:
            return "Positive"
        else:
            return "Negative" 

if __name__ == '__main__':
    print(main())

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a*b <= 0:
  print("Zero")
elif a>0:
  print("Positive")
else:
  if (a-b)%2 == 0:
    print("Negative")
  else:
    print("Positive")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if 0 < a:
    print('Positive')
elif a < 0 < b or a == 0 or b == 0:
    print('Zero')
else:
    if (b-a+1) % 2 == 0:
        print('Positive')
    else:
        print('Negative')

Submission status: Accepted

Solution code:
a, b = map(int,input().split())
if a > 0 and b > 0:
    print('Positive')
if a > 0 and b < 0:
    print('Zero')
if a < 0 and b > 0:
    print('Zero')
if a < 0 and b < 0:
    if (b-a) % 2 == 0:
        print('Negative')
    else:
        print('Positive')

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<0:
    if b>=0:
        print("Zero")
    else:
        num=int(b-a+1) #偶数なら正
        print("Positive" if num%2==0 else "Negative")
elif a==0:
    print("Zero")
else:
    print("Positive")

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if(a*b<=0):
  print("Zero")
else:
  if(a>0 or (b-a)%2==1):
    print("Positive")
  else:
    print("Negative")

Submission status: Accepted

Solution code:
a,b=map(int,input().split())

if a*b<=0:
    print("Zero")
elif a>0:
    print("Positive")
elif (b-a)%2 == 0:
    print("Negative")
else:
    print("Positive")

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a > 0:
    print("Positive")
elif a<=0<=b:
    print("Zero")
else: # b<0
    if (b-a)%2:
        print("Positive")
    else:print("Negative")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a > 0:
    print("Positive")
elif b >= 0:
    print("Zero")
elif (b-a+1) % 2 == 0:
    print("Positive")
else:
    print("Negative")

Submission status: Accepted

Solution code:
a,b=map(int,input().split());print("Zero"*(a*b<1)or "PNoesgia"[b<(b-a)%2<1::2]+"tive")

Submission status: Accepted

Solution code:
a,b=map(int,input().split());print(("Zero","PNoesgia"[b<(b-a)%2<1::2]+"tive")[a*b>0])

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a*b<=0:
	print("Zero")
elif b<0 and (b-a)%2==0:
	print("Negative")
else:
	print("Positive")

Submission status: Accepted

Solution code:
# 2019/08/15

a,b=map(int,input().split())
if a>0:ans=('Positive')
elif b<0:
    if -(a+b-1)%2:
        ans=('Negative')
    else:
        ans=('Positive')
else:ans=('Zero')

print(ans)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a <= 0  <= b: #0が含まれている時
    print ('Zero')
    exit()

if 0 < a: #全て正のとき
    print ('Positive')
    exit()

num = min(-1, b) - a + 1
if num % 2 == 0:
    print ('Positive')
else:
    print ('Negative')

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys, math, fractions, itertools


def solve(a: int, b: int):
    if a > 0:
        print('Positive')
    elif a <= 0 <= b:
        print('Zero')
    else:
        if (b-a) % 2 == 0:
            print('Negative')
        else:
            print('Positive')
    return


# Generated by 1.1.4 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    a = int(next(tokens))  # type: int
    b = int(next(tokens))  # type: int
    solve(a, b)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
a,b=[int(i) for i in input().split()]
if 0<a and 0<b:
  print("Positive")
elif a*b<=0:
  print("Zero")
elif (b-a)%2==1:
  print("Positive")
else:
  print("Negative")

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if (a>0 and b>0) or (a<0 and b<0\
	and (b-a)%2!=0):
	print("Positive")
elif a<=0<=b:
	print("Zero")
else:
	print("Negative")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a * b <= 0:
    print("Zero")
elif a > 0 and b > 0:
    print("Positive")
else:
    if (abs(a - b) + 1) % 2 == 0 :
        print("Positive")
    else:
        print("Negative")

Submission status: Accepted

Solution code:
a,b= map(int,input().split())
if a > 0:print('Positive')
elif b < 0:
    if (b-a+1) % 2 == 0:print('Positive')
    else:print('Negative')
elif a <= 0 <= b:print('Zero')

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<=0<=b:print('Zero')
elif 0<a:print('Positive')
elif b<0:print('PNoesgiattiivvee'[(b-a)%2==0::2])

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a > 0:
    ans = 'Positive'
elif b < 0:
    tmp = b - a + 1
    if tmp % 2 == 0:
        ans = 'Positive'
    else:
        ans = 'Negative'
else:
    ans = 'Zero'

print(ans)

Submission status: Accepted

Solution code:


a,b = map(int,input().split())

if a>0:
    print("Positive")
elif a == 0:
    print("Zero")
else:
    if b < 0:
        if (b-a)%2 == 0:
            print("Negative")
        else:
            print("Positive")
    else:
        print("Zero")

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<=0 and 0<=b:
  print('Zero')
elif a<0 and b<0:
  if (b-a)%2==1:
    print('Positive')
  else:
    print('Negative')
else:
  print('Positive')

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if (a <= 0) and (b >= 0):
    print("Zero")
elif (a < 0) and (b < 0):
    if (b - a + 1) % 2:
        print("Negative")
    else:
        print("Positive")
else:
    print("Positive")

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a*b <= 0:
  print("Zero")
elif a>0:
  print("Positive")
else:
  if (b-a+1) % 2 == 0:
    print("Positive")
  else:
    print("Negative")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
nega_num = 0
posi_num = 0
if a < 0 and b < 0:
    nega_num = b - a + 1
elif a < 0 and b >= 0:
    print('Zero')
    exit()
elif a == 0:
    print('Zero')
    exit()
elif a > 0:
    print('Positive')
    exit()
if nega_num % 2 == 1:
    print('Negative')
else:
    print('Positive')

Submission status: Accepted

Solution code:

def main():
    a,b = map(int,input().split())
    if a<=0 and 0<=b:
        print("Zero")
    else:
        if 0<a:
            print("Positive")

        else:
            if (b-a)%2==0:
                print("Negative")
            else:
                print("Positive")
if __name__=='__main__':
    main()

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<0 and b<0:
    if (b-a)%2==0:
        print("Negative")
    else:
        print("Positive")
elif a<0 and b>0:
    print("Zero")
elif a>0:
    print("Positive")
else:
    print("Zero")

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a*b<=0:print("Zero")
elif b<0 and (a-b)%2==0:print("Negative")
else:print("Positive")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a <= 0 and b >= 0:
    print("Zero")
elif a > 0 and b > 0:
    print('Positive')
elif a < 0 and b < 0:
    if (b - a + 1) % 2:
        print('Negative')
    else:
        print('Positive')

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if 0 < a and 0 < b:
    print("Positive")
elif a < 0 and b < 0:
    if (abs(a-b) + 1) % 2 == 0:
        print("Positive")
    else:
        print("Negative")
else:
    print("Zero")

Submission status: Accepted

Solution code:
# AGC002A - Range Product
def main():
    a, b = tuple(map(int, input().rstrip().split()))
    if a <= 0 <= b:
        print("Zero")
    elif 0 < a:
        print("Positive")
    else:
        l = abs(a - b) + 1
        print("Positive" if l % 2 == 0 else "Negative")


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
a,b = map(int,input().split())

if a*b <= 0:
    print('Zero')
elif a > 0 and b > 0:
    print('Positive')
else:
    cnt = b-a+1
    if cnt%2 == 0:
        print('Positive')
    else:
        print('Negative')

Submission status: Accepted

Solution code:
a,b = [int(i) for i in input().split()]
if(a<0):
  if(b<0):
    if((b-a)%2 ==0):
      print('Negative')
    else:
      print('Positive')
  else:
    print('Zero')
elif(a == 0):
  print('Zero')
else:
  print('Positive')

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a*b<=0:
    print("Zero")
elif a>0:
    print("Positive")
else:
    mab = (abs(a)%2 - abs(b)%2)%2 
    if mab == 0:
        print("Negative")
    else:
        print("Positive")

Submission status: Accepted

Solution code:
import logging

logging.basicConfig(level=logging.INFO, format="%(message)s")
#logging.disable(logging.CRITICAL)

def main():
    a, b = map(int, input().split())
    logging.info("Hello!")

    if a * b < 0:
        print("Zero")
    elif a > 0:
        print("Positive")
    else:
        if (b - a + 1) % 2 == 1:
            print("Negative")
        else:
            print("Positive")
            

    
    
if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
if a<=0 and 0<=b:
    print("Zero")
else:
    if 0<a:
        print("Positive")
    elif (b-a)%2==0:
        print("Negative")
    else:
        print("Positive")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
count_minus = abs(min(a,0) - min(b+1, 0))
if a <= 0 <= b:
    print('Zero')
elif count_minus % 2 == 0:
    print('Positive')
else:
    print('Negative')

Submission status: Accepted

Solution code:
a,b=map(int,input().split())
if a<=0<=b:
    print('Zero')
    exit()
if a>0:
    print('Positive')
    exit()
if (b-a)%2==1:
    print('Positive')
else:
    print('Negative')

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a * b < 0 and abs(a) == abs(b):
    print("Zero")
elif a >= 0 and b >= 0:
    print("Positive")
elif a < 0 and b >= 0:
    if a % 2 == 0:
        print("Positive")
    else:
        print("Negative")
elif a >= 0 and b < 0:
    if b % 2 == 0:
        print("Positive")
    else:
        print("Negative")
elif a < 0 and b < 0:
    if (abs((a - b)) + 1) % 2 == 0:
        print("Positive")
    else:
        print("Negative")

Submission status: Accepted

Solution code:
def MI():
    return map(int,input().split())
def I():
    return int(input())
def LI():
    return [int(i) for i in input().split()]

a,b=MI()

ans=['Positive','Negative','Zero']
if a>=1:
    k=0
elif a<=0 and b>=0:
    k=2
else:
    if (b-a+1)%2==1:
        k=1
    else:
        k=0
print(ans[k])

Submission status: Accepted

Solution code:
a, b = map(int,input().split())
if a == 0:
    print("Zero")
elif a > 0:
    print("Positive")
elif b >= 0:
    print("Zero")
elif (b-a+1) % 2 == 1:
    print("Negative")
else:
    print("Positive")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a <= 0 and 0 <= b:
    print("Zero")
elif a > 0:
    print("Positive")
else:
    if (b-a+1)&1 == 1:
        print("Negative")
    else:
        print("Positive")

Submission status: Accepted

Solution code:
A, B = map(int, input().split()) # 横に2個

if A <= 0 and 0 <= B:
    ans = 'Zero'
elif A > 0:
    ans = 'Positive'
elif (B - A) % 2 == 0:
    ans = 'Negative'
else:
    ans = 'Positive'

print(ans)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a > 0 and b > 0:
  print("Positive")
elif a < 0 and  b < 0:
  if (b - a + 1) % 2 == 0:
    print("Positive")
  else:
    print("Negative")
else:
  print("Zero")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if (a==0 or b==0) or (a<0 and b>0):
    print("Zero")

if a>0 and b>0:
    print("Positive")

if a<0 and b<0:
    if (abs(abs(a)-abs(b))+1)%2 == 0:
        print("Positive")
    else:
        print("Negative")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a * b <= 0:
    print("Zero")
    exit(0)
if a < 0:
    if (b - a + 1) % 2 == 0:
        print("Positive")
    else:
        print("Negative")
else:
    print("Positive")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a <= 0 <= b:
    print("Zero")
    exit()
if 0 < a:
    print("Positive")
    exit()

if b < 0:
    diff = abs(b - a) + 1
    if diff % 2 == 0:
        print("Positive")
    else:
        print("Negative")

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a > 0:
    print("Positive")
elif a <= 0 and b >= 0:
    print("Zero")
else:
    if (b - a) % 2 == 0:
        print("Negative")
    else:
        print("Positive")

Submission status: Accepted

Solution code:
s, e = [int(_) for _ in raw_input().split(" ")]
if s < 0 and 0 < e:
  print "Zero "
  exit()

if 0 < s:
  print "Positive"
  exit()

if (e - s + 1) % 2 == 0:
  print "Positive"
else:
  print "Negative"

Submission status: Accepted

Solution code:
a, b = map(int, input().split())

if a <= 0 and b >= 0:
  print('Zero')

if a > 0:
  print('Positive')
  
if b < 0:
  if (a - b + 1) % 2 == 0:
    print('Positive')
  else:
    print('Negative')

Submission status: Accepted

Solution code:
a, b = map(int,input().split())
if a<= 0 <=b:
   print("Zero")   
elif a > 0:
    print("Positive")
elif a==b:
    print("Positive")
elif (b-a)%2 == 0:
    print("Negative")
elif (b-a)%2 == 1:
    print("Positive")

Submission status: Accepted

Solution code:
a, b = map(int,input().split())
if a<= 0 <=b:
   print("Zero")
elif a > 0:
    print("Positive")
elif (b-a)%2 == 0:
    print("Negative")
else:
    print("Positive")

Submission status: Accepted

Solution code:
a, b = map(int,input().split())
if a <= 0 <= b:
    print("Zero")
elif a > 0:
    print("Positive")
elif (b-a) % 2 == 0:
    print("Negative")
else:
    print("Positive")