TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N=int(input())
A=[int(x) for x in input().split()]
guu=[]

result="APPROVED"
for i in range(N):
    if A[i]%2==0:
        guu.append(A[i])
for i in range(len(guu)):
    if (guu[i]%3!=0)and(A[i]%5!=0):
            result="DENIED"
            break

print(result)

N=int(input())
A=[int(x) for x in input().split()]
guu=[]

result="APPROVED"
for i in range(N):
    if A[i]%2==0:
        guu.append(A[i])
for i in range(len(guu)):
    if (guu[i]%3!=0)and(guu[i]%5!=0):
            result="DENIED"
            break

print(result)

Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = int(input())
l = list(map(int, input().split()))
def test():
  for i in l:
    if i%2 != 0 and i%3!=0 and i%5!=0:
      return "DENIED"
  return "APPROVED"
print(test())

n = int(input())
l = list(map(int, input().split()))
def test():
  for i in l:
    if i%2 != 0 and i%3!=0 and i%5!=0:
      return "DENIED"
    return "APPROVED"
  print(test())

n = int(input())
l = list(map(int, input().split()))
def test():
  for i in l:
    if i%3!=0 and i%5!=0:
      return "DENIED"
  return "APPROVED"
print(test())

    n = int(input())
    l = list(map(int, input().split()))
    def test():
      for i in l:
        if i%2 != 0 and i%3!=0 and i%5!=0:
          return "DENIED"
      return "APPROVED"
    print(test())

n = int(input())
l = list(map(int, input().split()))
def test():
  for i in l:
    if i%2 == 0 and i%3!=0 and i%5!=0:
      return "DENIED"
    return "APPROVED"
  print(test())

n = int(input())
l = list(map(int, input().split()))
def test():
  for i in l:
    if i%2 == 0 and i%3!=0 and i%5!=0:
      return "DENIED"
  return "APPROVED"
print(test())

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = int(input())
s = [int(x) for x in list(input().split()) if x%2 == 0]
ans = "APPROVED"
for i in s:
  if not i%5 != 0 && i%3 != 0:
    ans = "DENIED"
    pass
print(ans)


n = int(input())
s = [int(x) for x in list(input().split()) if int(x)%2 == 0]
ans = "APPROVED"
for i in s:
  if not i%5 != 0:
    ans = "DENIED"
    pass
  if not i%3 != 0:
    ans = "DENIED"
    pass
print(ans)


n = int(input())
s = [int(x) for x in list(input().split()) if int(x)%2 == 0]
ans = "APPROVED"
for i in s:
  if i%5 != 0 and i%3 != 0:
    ans = "DENIED"
    pass
print(ans)

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N=int(input())
li = list(map(int,input().split()))

for i in li:
  if i%2 ==0:
    if i%3 != 0 and i%5 != 0:
      print('DENIED')
      break
  continue
  print('APPROVED')

N=int(input())
li = list(map(int,input().split()))

for i in li:
  if i%2 ==0:
    if i%3 != 0 and i%5 != 0:
      print('DENIED')
      break
    else:
      continue
  print('APPROVED')

N=int(input())
li = list(map(int,input().split()))

for i in li:
  if i%2 ==0:
    if i%3 == 0 or i%5 == 0:
    else:
      print('DENIED')
      break

print('APPROVED')

N=int(input())
li = list(map(int,input().split()))

flag = 0

for i in li:
  if i%2 ==0:
    if i%3 != 0 and i%5 != 0:
      print('DENIED')
      flag = 1
      break
    else:
      continue
      
if flag = 0:
  print('APPROVED')

N=int(input())
li = list(map(int,input().split()))

for i in li:
  if i%2 ==0:
    if i%3 != 0 or i%5 != 0:
      print('DENIED')
      break
  continue
  print('APPROVED')


N=int(input())
li = list(map(int,input().split()))

for i in li:
  if i%2 ==0:
    if i%3 != 0 and i%5 != 0:
      print('DENIED')
      break
    else:
      continue
  continue
  print('APPROVED')

N=int(input())
li = list(map(int,input().split()))

for i in li:
  if i%2 ==0:
    if i%3 == 0 or i%5 == 0:
    else:
      print('DENIED')
      break
  print('APPROVED')


N=int(input())
li = list(map(int,input().split()))

flag = 0

for i in li:
  if i%2 ==0:
    if i%3 != 0 and i%5 != 0:
      print('DENIED')
      flag = 1
      break
    else:
      continue
      
if flag == 0:
  print('APPROVED')

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Runtime Error

Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
import sys
n=int(input())
a=map(int, input().split())
for i in a:
    if i%2==0 and i%3!=0 and i%5!=0:
        print("DEINED")
        sys.exit()


import sys
n=int(input())
a=map(int, input().split())
for i in a:
    if i%2==0 and i%3!=0 and i%5!=0:
        print("DENIED")
        sys.exit()

print("APPROVED")

Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n=int(input())
a=list(map(int, input().split()))
for i in a:
  if i%2==0 and i%3!=0 and i%5!=0:
    print('DENIED')
  	break
  else:
    print('APPROVED')

n=int(input())
a=list(map(int, input().split()))
for i in a:
  if i%2==0 and i%3!=0 and i%5!=0:
    print('DENIED')
  	exit()
  else:
    print('APPROVED')

_ = input()
a = list(map(int, input().split()))
 
for i in a:
	if i % 2 == 0 and i % 3 != 0 and i % 5 != 0:
		print('DENIED')
		break
else:
	print('APPROVED')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n=int(input())
a=list(map(int,input().split()))
x=[]
for i in a:
  if i%2==0:
    x+=i
for y in x:
  if y%3!=0 and y%5!=0:
    print('DENIED')
  else:
    print('APPROVED')

    

n=int(input())
a=list(map(int,input().split()))
x=[]
for i in a:
  if i%2==0:
    x+=i
for y in x:
  if x=[]:
    print('APPROVED')
  elif y%3!=0 and y%5!=0:
    print('DENIED')
  else:
    print('APPROVED')

    


n=int(input())
ans='APPROVED'
for i in range(n):
  x=int(input())
  if x%2==0:
    if x%3!=0 and x%5!=0:
      ans='DENIED'
      break
print(ans)

n=int(input())
a=list(map(int,input().split()))
count=0
for i in a:
  if i%2==0:
    count+=1
  if i%2==0 and i%3!=0 and i%5!=0:
    print('DENIED')
if count=0:
  print('DENIED')
else:
  print('APPROVED')

    


n=int(input())
ans='APPROVED'
a=list(map(int,input().split()))
for x in a:
  if x%2==0:
    if x%3!=0 and x%5!=0:
      ans='DENIED'
      break
print(ans)


Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = int(input())
A = list(map(int, input().split()))
for i in A:
    if (i%3==0 or i%5==0) and i%2==0:
        print('APPROVED')
    else:
        print('DENIED')

N = int(input())
A = list(map(int, input().split()))
for i in A:
    if i%2==0 and i%3!=0 and i%5!=0:
        ans=('DENIED')
        break
    else:
        ans=('APPROVED')
print(ans)

Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = int(input())
a = list(map(int,input().split()))
b = []
for i in a:
  if i%2==0:
    b.append(i)
c = 0
for i in b:
  if i%3!=0 or i%5!=0:
    c = c+1
  else:
    pass
if c==0:
  print("APPROVED")
else:
  print("DENIED")

n = int(input())
a = list(map(int,input().split()))
cnt=0
for i in range(n):
    if a[i]%2==0:
        if a[i]%3==0:
            pass
        elif a[i]%5==0:
            pass
        else:
            cnt+=1
if cnt==0:
    print("APPROVED")
else:
    #print(cnt)
    print("DENIED")

Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
 N = int(input())
    A = list(map(int, input().split(' ')))

    flag = True
    for i in range(N):
        if A[i] % 2 == 0:
            if A[i] % 3 == 0 or A[i] % 5 == 0:
                pass
            else:
                flag = False

    if flag:
        print("APPROVED")
    else:
        print("DENIED")

N = int(input())
A = list(map(int, input().split()))
for i in A:
    if i % 2 == 0:
        even_num.append(i)
for j in range(len(even_num)):
    if even_num[j] % 3 != 0 and even_num[j] % 5 != 0:
        print('DENIED')
        exit()
print('APPROVED')

N = int(input())
A = list(map(int, input().split(' ')))
flag = True
for i in range(N):
    if A[i] % 2 == 0:
        if A[i] % 3 == 0 or A[i] % 5 == 0:
            pass
        else:
            flag = False

if flag:
    print("APPROVED")
else:
    print("DENIED")


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = int(input())

A_list = list(map(int, input().split()))

for i in range(N):
    print(i)
    if A_list[i] % 2 == 0:
        if A_list[i] % 3 == 0 or A_list[i] % 5 == 0:
            if i == N-1:
                print("APPROVED")
            continue
        else:
            print("DENIED")
            exit()


N = int(input())

A_list = list(map(int, input().split()))

for i in range(N):
    if A_list[i] % 2 == 0:
        if A_list[i] % 3 == 0 or A_list[i] % 5 == 0:
            if i == N-1:
                print("APPROVED")
            continue
        else:
            print("DENIED")
            exit()


N = int(input())

A_list = list(map(int, input().split()))

for i in range(N):
    if A_list[i] % 2 == 0:
        if A_list[i] % 3 == 0 or A_list[i] % 5 == 0:
            continue
        else:
            print("DENIED")
            exit()

if i == N-1:
    print("APPROVED")


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = int(input())
l = list(map(int, input().split())
         
L = [i for i in l if i % 2 == 0]

K = [i for i in L if i % 3 != 0]

J = [i for i in K if i % 5 != 0]
         
if len(J) == 0:
         print("APPROVED")
else:
         print("DENIED")

N = int(input())
l = list(map(int, input().split())
         
L = [i for i in l if i % 2 == 0]

K = [i for i in L if i % 3 != 0]

J = [i for i in K if i % 5 != 0]
         
if len(J) == 0:
		print("APPROVED")
else:
        print("DENIED")

N = int(input())
l = list(map(int, input().split()))

L = [i for i in l if i % 2 == 0]
K = [i for i in L if i % 3 != 0]
J = [i for i in K if i % 5 != 0]

if len(J) == 0:
		print("APPROVED")
else:
        print("DENIED")

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = int(input())
li = list(map(int,input().split()))
flag = False
for i in li:
  if i % 6 == 0 or i % 10 == 0:
    continue
  else:
    print("DENIED")
    flag = True
if not flag:
  print("APPROVED")

n = int(input())
l = list(map(int,input().split()))
flag = False
for i in l:
  if i%2==0:
    if i%3!=0 and i%5!=0:
      flag=True
      break
if not flag:
  print('APPROVED')
else:
  print('DENIED')


Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = int(input())
A = list(map(int, input().split()))

for i in range(N):
  if A[i] % 2 == 0:
    if A[i] % 3 != 0 and A[i] % 5 != 0:
      print('DENIED')
      break
    elif i != N:
      continue
    else:
      print('APPROVED')

N = int(input())
A = list(map(int, input().split()))

for i in range(N):
  if A[i] % 2 == 0:
    if A[i] % 3 != 0 and A[i] % 5 != 0:
      print('DENIED')
      break()
      
print('APPROVED')

N = int(input())
A = list(map(int, input().split()))

for i in range(N):
  if A[i] % 2 == 0:
    if A[i] % 3 != 0 and A[i] % 5 != 0:
      print('DENIED')
      break
    elif i != N-1:
      continue
    else:
      print('APPROVED')
      break
  elif i != N-1:
    continue
  else:
    print('APPROVED')
    break

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = int(input())
a = [int(x) for x in input().split()]

a_even = []
for ai in a:
    if ai%2 == 0:
        a_even += [ai]

for a_eveni in a_even:
    if a_eveni%3 != 0 or a_eveni%5 != 0:
        ans = "DENIED"
    else:
        ans = "APPROVED"
print(ans)

import numpy as np

n = int(input())
a = np.array([int(x) for x in input().split()])

a1 = list(map(lambda x: bool(x/2%1), a))
a2 = list(map(lambda x: bool(x/3%1), a/2))
a3 = list(map(lambda x: bool(x/5%1), a/2))
a4 = list(map(lambda x, y: x and y, a2, a3))
if a1.count(False) == a4.count(False):
    print("APPROVED")
else:
    print("DENIED"

n = int(input())
a = [int(x) for x in input().split()]

a_even = []
for ai in a:
    if ai%2 == 0:
        a_even += [ai]

ans = "APPROVED"
for a_eveni in a_even:
    if a_eveni%3 != 0 or a_eveni%5 != 0:
        ans = "DENIED"
        break

print(ans)

import numpy as np

n = int(input())
a = np.array([int(x) for x in input().split()])

aa = a[a%2 == 0]
if np.all((aa%3 == 0) | (aa%5 == 0)):
    print("APPROVED")
else:
    print("DENIED")

Verdicts: Runtime Error

Runtime Error

Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = list[int(i) for i in input().split]
A = list[int(i) for i in input().split]
if all([i%2==1 for i in A]):
    print('APPROVED')
else:
    even = [i for i in A if i%2==0]
    even = [0 if i%3==0 or i%5==0 else 1 for i in even]
    if max(even)==1:
        print('DENIED')
    else:
        print('APPROVED')

N = [int(i) for i in input().split]
A = [int(i) for i in input().split]
if all([i%2==1 for i in A]):
    print('APPROVED')
else:
    even = [i for i in A if i%2==0]
    even = [0 if i%3==0 or i%5==0 else 1 for i in even]
    if max(even)==1:
        print('DENIED')
    else:
        print('APPROVED')

N = list[int(i) for i in input().split]
A = list[int(i) for i in input().split]
if all([i%2==1 for i in A]):
    print('APPROVED')
else:
    even = [i for i in A if i%2==0]
    print(even)
    even = [0 if i%3==0 or i%5==0 else 1 for i in even]
    if max(even)==1:
        print('DENIED')
    else:
        print('APPROVED')

list = [int(i) for i in input().split()]
N = list[0]
A = list[1:N+1]
if all([i%2==1 for i in A]):
    print('DENIED')
else:
    even = [i for i in A if i%2==0]
    even = [0 if i%3==0 or i%5==0 else 1 for i in even]
    if max(even)==1:
        print('DENIED')
    else:
        print('APPROVED')

N = [int(i) for i in input().split()]
A = [int(i) for i in input().split()]
if all([i%2==1 for i in A]):
    print('APPROVED')
else:
    even = [i for i in A if i%2==0]
    even = [0 if i%3==0 or i%5==0 else 1 for i in even]
    if max(even)==1:
        print('DENIED')
    else:
        print('APPROVED')

Verdicts: Runtime Error

Runtime Error

Runtime Error

Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = int(input())
A = list(map(int,input().split()))
if all(v%2==1 or v%3==0 or v%5==0):
    print("APPROVED")
else:
    print("DENIED")


N = int(input())
A = list(map(int,input().split()))
if all(v%2==1 or v%3==0 or v%5==0 for v in A):
    print("APPROVED")
else:
    print("DENIED")


Verdicts: Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
num = int(input())
lst = list(map(int,input().split()))
count = 0
counta == 0
for i in range(num):
  if lst[i] % 2 == 0:
    count += 1
    if lst[i] % 3 == 0 or lst[i] % 5 == 0:
      counta += 1
if count == counta:
  print("APPROVED")
else:
  print("DENIED")

num = int(input())
lst = list(map(int,input().split()))
count = 0
counta = 0
for i in range(num):
  if lst[i] % 2 == 0:
    count += 1
    if lst[i] % 3 == 0 or lst[i] % 5 == 0:
      counta += 1
if count == counta:
  print("APPROVED")
else:
  print("DENIED")

Verdicts: Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
#!usr/bin/env python3
import sys
import math
import string
import collections
import fractions
import random
from operator import itemgetter
import itertools
from collections import deque
import copy
import heapq
import bisect

MOD = 10 ** 9 + 7
INF = float('inf')
input = lambda: sys.stdin.readline().strip()

sys.setrecursionlimit(10 ** 8)

N = int(input())
A = list(map(int,input().split()))
for i in A:
    if i%2 == 0 and i%3 != 0 and i%5 != 0:
        print("DENIED")
        sys.exit()
print("APPEOVED")

#!usr/bin/env python3
import sys
import math
import string
import collections
import fractions
import random
from operator import itemgetter
import itertools
from collections import deque
import copy
import heapq
import bisect

MOD = 10 ** 9 + 7
INF = float('inf')
input = lambda: sys.stdin.readline().strip()

sys.setrecursionlimit(10 ** 8)

N = int(input())
A = list(map(int, input().split()))
for i in A:
    if i % 2 == 0 and i % 3 != 0 and i % 5 != 0:
        print("DENIED")
        sys.exit()
print("APPROVED")


Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N=int(input())
a1=input().split()
a2=[int(i) for i in a1]
for i in a2:
    if i%2==0 and i%3!=0 and 1%5!=0:
        print('DENIED')
        break
else:
    print('APPROVED')

N=int(input())
a1=input().split()
a2=[int(i) for i in a1]
for i in a2:
    if i%2==0 and i%3!=0 and i%5!=0:
        print('DENIED')
        break
else:
    print('APPROVED')

Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):


N = int(input())
a = list(map(int(input().split())))
for i in range(N):
    if a[i] % 2 == 0:
        if a[i] % 3 != 0 and a[i] % 5 != 0:
            print("DENIED")
            exit(0)
print("APPROVED")


N = int(input())
a = list(map(int,input().split()))
result = "APPROVED"
for i in range(N):
    if a[i] % 2 == 0:
        if a[i] % 3 != 0 and a[i] % 5 != 0:
            result = "DENIED"
            break
print(result)


Verdicts: Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
A = list(map(int, input().split()))
count = 0
for a in A:
  if (a % 2 == 0 and a % 3 != 0) and (a % 2 == 0 and a % 5 != 0):
    count = count + 1

if count => 1 :
  print('DENIED')
else:
  print('APPROVED')

A = list(map(int, input().split()))
N = int(input())
count = 0
for a in A:
  if (a % 2 == 0 and a % 3 != 0) and (a % 2 == 0 and a % 5 != 0):
    count = count + 1

if count >= 1 :
  print('DENIED')
else:
  print('APPROVED')

A = list(map(int, input().split()))
N = int(input())
count = 0
for a in A:
 if (a % 2 == 0 and a % 3 != 0) and (a % 2 == 0 and a % 5 != 0):
   count = count + 1

if count >= 1 :
 print('DENIED')
else:
 print('APPROVED')

N = input()
A = list(map(int, input().split()))

for i in A:
    i = int(i)
    if i % 2 == 0:
        if i % 3 !=0 and i % 5 !=0:
            print("DENIED")
            exit()
print("APPROVED")

Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = int(input())
A = [int(zz) for zz in input().split()]

for i in A:
    if i%2 == 0:
        if i%3 != 0 or i%5 != 0:
            print('DENIED')
            exit()

print('APPROVED')


N = int(input())
A = [int(zz) for zz in input().split()]
li = []
li2 = []
n = 0
for i in A:
    if i%2 == 0:
        li.append(i%3)
        li2.append(i%5)
        n += 1

for i in range(n):
    if li[i]*li2[i] != 0:
        print('DENIED')
        exit()
print('APPROVED')


Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = int(input())
m = list(map(int, input().split()))
m = set(m)

for i int range(len(m))
    if i % 2 == 0:
        if i % 5 == 0 or i % 3 == 0:
            ans = 'APPROVED'
        else:
            ans = 'DENIED'

print(ans)

n = int(input())
m = list(map(int, input().split()))

ans = "APPROVED"

for i in range(len(m)):
    if ans == "DENIED":
        break;
    if m[i] % 2 == 0:
        if m[i] % 5 == 0 or m[i] % 3 == 0:
            ans = 'APPROVED'
        else:
            ans = 'DENIED'
            break;

print(ans)

Verdicts: Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = input()
l = list(map(int, input().split()))
result = 'APPROVED'
for i in l:
  if i % 2 == 0:
    if i % 3 != 0 or i % 5 != 0:
      result = 'DENIED'
      break
print(result)

    

n = input()
l = list(map(int, input().split()))
result = 'APPROVED'
for i in l:
  if i % 2 == 0:
    if i % 3 != 0 and i % 5 != 0:
      result = 'DENIED'
      break
print(result)

Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = int(input())
A = list(map(int,input().split()))

flag =0
for i in A:
    if (i %2 ==1) or ((i%3)==0 or (i%5) == 0):
        pass
    else:
        flag =1

if flag== 1:
    print("DENIED")
else:
    print("APPROED")
    

N = int(input())
A = list(map(int,input().split()))

flag =0
counter =0
for i in A:
    counter +=1
    if (i %2 ==1) or ((i%3)==0 or (i%5) == 0):
        pass
    else:
        flag =1

if flag== 1:
    print("DENIED")
else:
    print("APPROVED")



Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = int(input())
l = list(map(int,input().split()))
flag = False
for i in l:
  if i%2==0:
    if i%3!=0 or i%5!=0:
      flag=True
      break
if not flag:
  print('APPROVED')
else:
  print('DENIED')

n = int(input())
l = list(map(int,input().split()))
flag = False
for i in l:
  if i%2==0:
    if i%3!=0 and i%5!=0:
      flag=True
      break
if not flag:
  print('APPROVED')
else:
  print('DENIED')

Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = int(input())
arr = list(map(int, input().split()))

for x in arr:
    if ((x % 2) == 0) and (x % 3 or x % 5):
        break
else:
    print("APPROVED")

print("DENIED")


N = int(input())
arr = list(map(int, input().split()))

for x in arr:
    if ((x % 2) == 0) and (x % 3 or x % 5):
        print("DENIED")
        break
else:
    print("APPROVED")



N = int(input())
arr = list(map(int, input().split()))

for x in arr:
    if ((x % 2) == 0) and (x % 3 * x % 5):
        print("DENIED")
        break
else:
    print("APPROVED")



Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = int(input())
L = list(map(int, input().split()))

ans = "APPROVED"
for i in range(N):
  if L[i]%2 == 0:
    if L[i]%3 == 0 and L[i]%5 == 0:
      pass
    else:
      ans = "DENIED"
      break
      
print(ans)
      

N = int(input())
L = list(map(int, input().split()))

ans = "APPROVED"
for i in range(N):
  if L[i]%2 == 0:
    if L[i]%3 == 0 or L[i]%5 == 0:
      pass
    else:
      ans = "DENIED"
      break
      
print(ans)
      


Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
S_list = [input() for i in range(2)]
S_list_1 = S_list[1].split()

for i in S_list_1:   
    if int(i) % 2 == 0 :
        if i % 3 !=0 and i % 5 !=0 :
            result="DENIED"
            break
    else:
        result="APPROVED"        
print(result)

S_list = [input() for i in range(2)]
S_list_1 = S_list[1].split()

even_list = []
for i in S_list_1:   
    if int(i) % 2 == 0:
        even_list.append(int(i))

if (even_list is None) == False:
    even_list =[1]
    
for i in even_list:
    if i % 3 ==0 or i % 5 ==0 :
        result="APPROVED"
    else:
        result="DENIED"
        break
print(result)

S_list = [input() for i in range(2)]
S_list_1 = S_list[1].split()
   
for i in S_list_1:
    if int(i) % 6 ==0 or int(i) % 10 ==0 :
        result="APPROVED"
    else:
        result="DENIED"
        break
print(result)

S_list = [input() for i in range(2)]
S_list_1 = list(map(int,S_list[1].split()))

for i in S_list_1:   
    if i % 2 == 0 :
        if i % 3 !=0 and i % 5 !=0 :
            result="DENIED"
            break
    else:
        result="APPROVED"        
print(result)

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = int(input())
arr = [input() for _ in range(n)]
dic = {}
for i in range(n):
    if arr[i] not in dic:
        dic[arr[i]] = 1
    else:
        dic[arr[i]] += 1
largest = max(dic.values())
ans = []
for keys in dic.keys():
    if dic[keys] == largest:
        ans.append(keys)
ans = sorted(ans)
for words in ans:
    print(words)


N = int(input())
A = list(map(int, input().split()))

for a in A:
    if a % 2 == 1:
        continue
    if a % 3 == 0 or a % 5 == 0:
        continue
    print('DENIED')
    exit()
print('APPROVED')

Verdicts: Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N=int(input())
A=list(map(int,input().split()))
l=[]
for i in range(N):
    if A[i]%2==0:
        l.append(A[i])
flag=True
for i in range(N):
    if l[i]%3==0 or l[i]%5==0:
        pass
    else:
        flag=False
if flag:
    print("APPROVED")
else:
    print("DENIED")

N=int(input())
A=list(map(int,input().split()))
l=[]
for i in range(N):
    if A[i]%2==0:
        l.append(A[i])
flag=True
for i in range(len(l)):
    if l[i]%3==0 or l[i]%5==0:
        pass
    else:
        flag=False
if flag:
    print("APPROVED")
else:
    print("DENIED")

Verdicts: Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = input()
A = map(int, input().split())
even = []
count = 0
for x in A:
    if x % 2 == 0:
        even.append(x)
for x in even:
    if x%3 == 0 or x%5 == 0:
        count += 1
if count == len(even):
    print("Approved")
else:
    print("Denied")

N = input()
A = map(int, input().split())
even = [x for x in A if x%2 == 0]
count = []
for x in even:
    if x%3 == 0 or x%5 == 0:
        count.append(True)
if len(count) == len(even):
    print("Approved")
else:
    print("Denied")

N = input()
A = map(int, input().split())
even = []
count = []
for x in A:
    if x % 2 == 0:
        even.append(x)
for x in even:
    if x%3 == 0 or x%5 == 0:
        count += 1
if count == len(even):
    print("Approved")
else:
    print("Denied")


N = input()
A = map(int, input().split())
even = []
count = 0
for x in A:
    if x % 2 == 0:
        even.append(x)
for x in even:
    if x%3 == 0 or x%5 == 0:
        count += 1
    else:
        count -= 1
if count == len(even):
    print("Approved")
else:
    print("Denied")

n = input()
_list = input().split(" ")
_list = [int(x) for x in _list]
even = [x for x in _list if x % 2==0]
answer = []
for x in even:
    if x % 3 == 0 or x % 5 == 0:
        answer.append(True)
if len(even) ==len(answer):
    print("APPROVED")
else:
    print("DENIED")

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
n = int(input())
arr = []
arr = list(map(int, input().split()))
flag = 0
for i in range(n):
  num = arr[i]
  if num % 2 == 0:
    if (num % 6 == 0) or (num % 10 == 0):
      flag = 1
    else:
      flag = 0
    if flag == 1:
      print("APPROVED")
    else:
      print("DENIED")

int n = input()
arr = []
arr = list(map(int, input().split()))
for i in range(n):
  num = arr[i]
  if num % 2 == 0:
    if (num % 6 == 0) or (num % 10 == 0):
      print("APPROVED")
    else:
      print("DENIED")

n = int(input())
arr = []
arr = list(map(int, input().split()))
flag = 0
count = 0
for i in range(n):
  num = arr[i]
  if num % 2 == 0:
    count += 1
    if(num % 6 == 0) or (num % 10 == 0):
      flag += 1
      
if flag == count:
    print("APPROVED")
else:
    print("DENIED")


Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
import sys
n=int(input())
a=list(map(int,input().split()))
for i in a:
  if i%2==0:
    if i%3!=0 or i%5!=0:
      print("DENIED")
      sys.exit()

print("APPROVED")

import sys
n=int(input())
a=list(map(int,input().split()))
for i in a:
  if i%2==0:
    if i%3!=0 and i%5!=0:
      print("DENIED")
      sys.exit()
      
print("APPROVED")



Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N = input()
numList = input()


for num in numList:
  if num % 2 == 0:
    judge1 = num % 3 == 0
    judge2 = num % 5 == 0
    approve = judge1 or judge2
    if not approve:
      print('DENIED')
      exit()
print('APPROVED')

N = input()
numList = input().split(' ')
print(numList)
for num in numList:
  num = int(num)
  if num % 2 == 0:
    judge1 = num % 3 == 0
    judge2 = num % 5 == 0
    approve = judge1 or judge2
    if not approve:
      print('DENIED')
      exit()
print('APPROVED')

N = input()
numList = input().split(' ')
for num in numList:
  num = int(num)
  if num % 2 == 0:
    judge1 = num % 3 == 0
    judge2 = num % 5 == 0
    approve = judge1 or judge2
    if not approve:
      print('DENIED')
      exit()
print('APPROVED')

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N=int(input())
A=list(map(int,input().split()))
print("APPROVED" if all(i%2==0 and (i%3==0 or i%5==0) for i in A) else "DENIED")

N=int(input())
A=list(map(int,input().split()))
print("APPROVED" if all([i%2!=0 or i%3==0 or i%5==0 for i in A]) else "DENIED")

Verdicts: Wrong Answer

Accepted
Problem: You are an immigration officer in the Kingdom of AtCoder. The document carried by an immigrant has some number of integers written on it, and you need to check whether they meet certain criteria.  According to the regulation, the immigrant should be allowed entry to the kingdom if and only if the following condition is satisfied:    * All even numbers written on the document are divisible by 3 or 5.  If the immigrant should be allowed entry according to the regulation, output `APPROVED`; otherwise, print `DENIED`.

Submission attempts (in order):
N=int(input())
A=list(map(int,input().split()))
lis=[]
flag=1

for i in A:
  if i%2==0:
    lis.append(i)
    
for j in lis:
  if j%3!=0 and j%5!=0:
    flag=0
print("DENIED"if flag==0 else "APPROVE")

N=int(input())
A=list(map(int,input().split()))
lis=[]
flag=1

for i in A:
  if i%2==0:
    lis.append(i)
    
for j in lis:
  if j%3!=0 and j%5!=0:
    flag=0
print("DENIED"if flag==0 else "APPROVED")

Verdicts: Wrong Answer

Accepted