Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1    
  print(s)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)

Buggy python submission (verdict: Runtime Error):
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
  if s > 10**18:
      s = -1    
      break
  print(s)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in range(n):
    s *= a[i]
  if s > 10**18:
      s = -1    
  print(s)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)

Buggy python submission (verdict: Runtime Error):
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
  if s > 10**18:
      s = -1    
      break
  print(s)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
  if s > 10**18:
      s = -1    
  print(s)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)

Buggy python submission (verdict: Runtime Error):
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  prrint(0)
else:
  s = 1
  for i in a :
    s *= i
  if s > 10**18:
      print("-1")
  else:
      print(s)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)

Buggy python submission (verdict: Runtime Error):
n = int(input())
a = list(map(int, input().split()))
s = 1
if 0 in a:
  prrint(0)
else:
  for i in a :
  s *= i
  if s > 10**18:
    print("-1")
  else:
    print(s)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
a = list(map(int, input().split()))
s = 1
for i in a :
  s *= i
if s > 10**18:
  print("-1")
else:
  print(s)

Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)

Buggy python submission (verdict: Runtime Error):
n = int()
a = list[map(int, input().split())]
s = 1
for i in n+1 :
  ans = s*a[i]
if ans => 10**8:
  print("-1")
else:
  print(ans)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)

Buggy python submission (verdict: Runtime Error):
n = int()
a = list(map(int, input().split()))
s = 1
for i in a[] :
  ans = s*a[i]
if ans => 10**8:
  print("-1")
else:
  print(ans)

Fixed submission:
n = int(input())
a = list(map(int, input().split()))
if 0 in a:
  print(0)
else:
  s = 1
  for i in a :
    s *= i
    if s > 10**18:
      s = -1
      break
  print(s)