TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

flag = True
for i in range(N):
    target = A_list[i]
    for j in range(i+1, N):
        if target == A_list[j]:
            flag = False
            break
    if flag == False:
        break

if flag:
    print('Yes')
else:
    print('No')



N=int(input())
A_list=list(map(int,input().split()))
A_list_sorted=sorted(A_list)


flag = True
for i in range(N-1):
    target = A_list_sorted[i]

    if target == A_list_sorted[i+1]:
        flag = False
        break

if flag:
    print('YES')
else:
    print('NO')

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = input()
inp = input()
listA = inp.split(' ')
count = 0
for moji in lintA:
  youso = listA.count(moji)
  if youso == 1:
    count += 1
  else:
    print('NO')
    break
if count == len(listA):
  print('YES')

N = input()
inp = input()
listA = inp.split(' ')
out = YES
for k in listA:
  count = 0
  for j in listA:
    if k == j:
      count += 1
      if count >= 2:
        out = NO
        break
print(out)
  

N = int(input())
inputA = input()
listA = inputA.split(' ')
listA.sort()
output = 'YES'
for i in range (len(listA) - 1):
    if listA[i] == listA[i + 1]:
        output = 'NO'
print(output)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
lst = [int(n) for n in input().split(" ")]
st = set(lst)
if len(lst) == len(st):
  print("Yes")
else:
  print("No")

N = int(input())
lst = [int(n) for n in input().split(" ")]
st = set(lst)
print(lst)
print(st)
print(len(lst))
print(len(st))
if len(lst) == len(st):
  print("YES")
else:
  print("NO")

N = int(input())
lst = [int(n) for n in input().split(" ")]
st = set(lst)
if len(lst) == len(st):
  print("YES")
else:
  print("NO")

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n = int(input())
nums = list(map(int,input().split()))
c = 0
nums = sorted(nums)

for i in range(n-1):
    if nums[i] == nums[i+1]:
        c += 1
        break
    
if c != 0:
    print('No')

else:
    print('Yes')

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

l = [0]*200001

for num in nums:
    l[num] += 1

if max(nums) == 1:
    print('YES')

else:
    print('NO')

n = int(input())
nums = list(map(int,input().split()))
c = 0
nums = sorted(nums)

for i in range(n-1):
    if nums[i] == nums[i+1]:
        c += 1
        break
    
if c != 0:
    print('NO')

else:
    print('YES')

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
from collections import Counter
input()
lst=list(map(int,input().split()))
dic=dict(Counter(lst))
x=max(list(dic.values()))-1
if x:
  print('No')
else:
  print('Yes')

from collections import Counter
input()
lst = input().split()
dic = dict(Counter(lst))
x = max(list(dic.values())) - 1
if x:
    print('No')
else:
    print('Yes')

from collections import Counter
input()
lst=list(map(int,input().split()))
dic=dict(Counter(lst))
x=max(lst(dic.values()))-1
if x:
  print('No')
else:
  print('Yes')

from collections import Counter
input()
lst=input().split()
dic=dict(Counter(lst))
x=max(list(dic.values()))-1
if x:
  print('No')
else:
  print('Yes')

from collections import Counter
input()
lst = input().split()
dic = dict(Counter(lst))
x = max(list(dic.values())) - 1
if x:
    print('NO')
else:
    print('YES')

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
A = list(map(int,input().split()))
if len(A) == len(list(set(A))):
    print("Yes")
else:
    print("No")

N = int(input())
A = list(map(int,input().split()))
if len(A) == len(list(set(A))):
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import sys
n=int(input())
x=list(map(int,input().split()))

c=[]

for i in x:
    if i not in c:
        c.append(i)
    else:
        print('No')
        sys.exit()

print('Yes')

import sys
n=int(input())
x=list(map(int,input().split()))
x.sort()

for i in range(n-1):
    if x[i]==x[i+1]:
        print('NO')
        sys.exit()
        
print('YES')

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

    is_break = False
    seen = []
    for a in A:
        if a not in seen:
            seen.append(a)
        else:
            is_break = True
            break:
    
    if is_break:
        print("NO")
    else:
        print("YES")


if __name__ == '__main__':
    main()

def main():
    N = int(input())
    A = list(map(int, input().split(' ')))

    is_break = False
    seen = set()
    for a in A:
        if a not in seen:
            seen.add(a)
        else:
            is_break = True
            break
    
    if is_break:
        print("NO")
    else:
        print("YES")


if __name__ == '__main__':
    main()

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
 n = int(input())
    a = list(map(int, input().split()))
    seta = set(a)
    ans = 'YES' if len(a) == len(seta) else 'NO'
    print(ans)    

 n = int(input())
    a = list(map(int, input().split()))
    seta = set(a)
    ans = 'YES' if len(a) == len(seta) else 'NO'
    print(ans)    

n = int(input())
a = list(map(int, input().split()))
seta = set(a)
if len(a)==len(seta):
  print("YES")
else:
  print("NO")


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

len2 = len(set(A))

if N == len2:
    print('Yes')
else:
    print('No')

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

len2 = len(set(A))

if N == len2:
    print('Yes')
else:
    print('No')

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

len2 = len(set(A))
if N == len2:
    print('YES')
else:
    print('NO')

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n = int(input())
a = input().split(" ")
b = set(a)
print "YES" if len(b) > len(a) else "NO"

n = int(input())
a = input().split(" ")
b = set(a)
if len(b)<len(a):
    print("NO")
else:
    print("YES")


Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n=int(input())
a=list(map(int,input().split()))
list=[]
for i in a:
	if a in list:
		print("NO")
		break
	list.append(a)
else:
	print("YES")


n=int(input())
a=list(map(int,input().split()))
a.sort()
for i in range(n-1):
	if a[i]==a[i+1]:
		print("NO")
		break
else:
	print("YES")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

flag = True

for i in range(n-1):
    if a[i] == a[i+1]: flag = False

if flag:
    print("Yes")
else:
    print("No")


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

flag = True

for i in range(n-1):
    if a[i] == a[i+1]: flag = False

if flag:
    print("YES")
else:
    print("NO")


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
# -*- coding: utf-8 -*-
N = int(input())
A_list = list(map(int, input().split()))

print("Yes" if len(A_list) == len(set(A_list)) else "No")

# -*- coding: utf-8 -*-
N = int(input())
A_list = list(map(int, input().split()))

print("YES" if len(A_list) == len(set(A_list)) else "NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
from collections import Counter
from operator import itemgetter

N = int(input())
A = Counter(map(int,input().split()))
A1 = list(A.items())
A1 = sorted(A1,key=itemgetter(1),reverse = True)

if A1[0][1] == 1:
    print('Yes')
else:
    print('No')


from collections import Counter
from operator import itemgetter

N = int(input())
A = Counter(map(int,input().split()))
A1 = list(A.items())
A1 = sorted(A1,key=itemgetter(1),reverse = True)
print(A1)

if A1[0][1] == 1:
    print('YES')
else:
    print('NO')

from collections import Counter
from operator import itemgetter

N = int(input())
A = Counter(map(int,input().split()))
A1 = list(A.items())
A1 = sorted(A1,key=itemgetter(1),reverse = True)
#print(A1)

if A1[0][1] == 1:
    print('YES')
else:
    print('NO')


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n = int(input())
li = map(int,input().split())
print('NO' if len(li)!=len(set(li)) else 'YES')

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

print('NO' if len(li) > len(set(li)) else 'YES')

input()
li = list(map(int, input().split()))
print('NO' if len(li)>len(set(li)) else 'YES')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n=int(input())
c=sorted(list(map(int, input().split())))
ans = 0

for i in range(n-1):
    if c[i] == c[i+1]:
        ans +=1

if ans == 0:
    print('Yes')
if ans != 0:
    print('No')

n=int(input())
c=sorted(list(map(int, input().split())))
ans = 0

for i in range(n-1):
    if c[i] == c[i+1]:
        ans +=1

if ans == 0:
    print('YES')
if ans != 0:
    print('NO')

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
A = set(list(map(Int, input().split())))
if len(A) == N:
    print("YES")
else:
    print("NO")


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

if len(A) == N:
    print("YES")
else:
    print("NO")


Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

s = {}
flag = 0

for i in range(n):
    t = a[i]
    s.setdefault(t, 0)
    if s[t] == 0:
        s[t] = 1
    else:
        print("No")
        flag = 1
        break

if flag == 0:
    print("Yes")

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

s = {}
flag = 0

for i in range(n):
    t = a[i]
    s.setdefault(t, 0)
    if s[t] == 0:
        s[t] = 1
    else:
        print("No")
        flag = 1
        break

if flag == 0:
    print("Yes")

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

s = {}
flag = 0

for i in range(n):
    t = a[i]
    s.setdefault(t, 0)
    if s[t] == 0:
        s[t] = 1
    else:
        print("No")
        flag = 1
        break

if flag == 0:
    print("Yes")

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

s = {}
flag = 0

for i in range(n):
    t = a[i]
    s.setdefault(t, 0)
    if s[t] == 0:
        s[t] = 1
    else:
        print("NO")
        flag = 1
        break

if flag == 0:
    print("YES")

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
all_num = int(input())
num_list = [int(i) for i in input().split()]

if len(num_list) == set(num_list):
    print('YES')
else:
    print('NO')

all_num = int(input())
num_list = [int(i) for i in input().split()]

if len(num_list) == len(set(num_list)):
    print('YES')
else:
    print('NO')

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
S = map(int, input().split())
if len(set(S)) == N:
  print('Yes')
else:
  print('No')

N = int(input())
S = map(int, input().split())
if len(set(S)) == N:
  print('YES')
else:
  print('NO')


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n = int(input())
a = list(map(int, input().split())
if len(set(a)) == n:
         print('YES')
else:
         print('NO')

n = int(input())
a = list(map(int, input().split()))
if len(set(a)) == n:
    print('YES')
else:
    print('NO')


Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
def has_duplicates(seq):
    return len(seq) != len(set(seq))

N=int(input())
A=list(map(int,input().split()))
if has_duplicates(A):
    print('No')
else:
    print('Yes')

N=int(input())
A=list(map(int,input().split()))
l=[]
for i in range(N):
    if A[i] in l:
        print('No')
        exit()
    l.append(A[i])
print('Yes')

def has_duplicates(seq):
    return len(seq) != len(set(seq))

N=int(input())
A=list(map(int,input().split()))
if has_duplicates(A):
    print('No')
else:
    print('Yes')

def has_duplicates(seq):
    return len(seq) != len(set(seq))

N=int(input())
A=list(map(int,input().split()))
if has_duplicates(A):
    print('NO')
else:
    print('YES')

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

if len(set(a))!=len(a):
    print("No")
else:
    print("Yes")

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

if len(set(a))!=len(a):
    print("NO")
else:
    print("YES")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

distinct = True
dic = {}

for x in a:
    if x in dic:
        distinct = False
        break
    dic[x] = True

if distinct:
    print("Yes")
else:
    print("No")

n = input()
a = [x for x in input().split(' ')]
a.sort();

isDistinct = True
for i in range(len(a)):
    if(a[i] == a[i - 1]):
        isDistinct = False
        break;

if isDistinct:
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n = input()
y = map(int, input().split())
k = list(y)
t = len(set(k))
q = len(k)

if q > t:
    print("No")
else:
    print("Yes")

n = input()
y = map(int, input().split())
k = list(y)
t = len(set(k))
q = len(k)

if q > t:
    print("NO")
else:
    print("YES")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
x = int(input(""))
l = list()
flag = 0
for i in range(0, x):
    temp = input("")
    if temp in l:
        flag = 1
    if temp not in l:
        l.append(temp)
if flag == 1:
    print("NO")
else:
    print("YES")



x = int(input(""))
l = list()
flag = 0
arr = [int(x) for x in input().split()]
arr2=set(arr)
l=len(arr)
l2=len(arr2)
if l!=l2:
    print("NO")
else:
    print("YES")



Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

if len(set(A)) == N:
    print("Yes")
else:
    print("No")

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

if len(set(A)) == N:
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import collections

N=input()
A=[int(s) for s in input().split(" ")]

B=collections.Counter(A)

print("No" if len(A)!=len(B) else "Yes")

import collections

N=input()
A=[int(s) for s in input().split(" ")]

B=collections.Counter(A)

print("NO" if len(A)!=len(B) else "YES")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

if len(set(A)) == len(A):
    print("Yes")
else:
    print("No")

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

if len(set(A)) == N:
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

for i in range(N-1):
    for j in range(N-i):
        if A[i] == A[i+j+1]:
            print("NO")
            exit()

print("YES")

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

for i in range(N-1):
    if A[i] == A[i+1]:
        print("NO")
        exit()

print("YES")

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import numpy as np

n = int(input())
An = np.array(map(int, input().split()))

if len(np.unique(An)) == n:
  print('YES')
else:
  print('NO')


import numpy as np

n = int(input())
An = list(map(int, input().split()))
An = np.array(An)

if len(np.unique(An)) == n:
  print('YES')
else:
  print('NO')


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

if N == len(set(A)):
    print('Yes')
else:
    print('No')

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

if N == len(set(A)):
    print('YES')
else:
    print('NO')

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n = int(input())
a = [int(k) for k in input().split()]
b=0
for j in range(n):
    for k in range(n):
        if a[j]==a[k] and j!=k:
        b+=1
        break
    break
if b==0:
  print('YES')
else:
  print('NO')


n = int(input())
a = [int(k) for k in input().split()]
a.sort()
for i in range(n-1):
    if a[i] < a[i+1]:
        pass
    else:
        print("NO")
        exit()
print("YES")

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n=int(input())
*a,=map(int,input().split())
if len(set(a)) == len(a):
    print("Yes")
else:
    print("No")
    

n=int(input())
*a,=map(int,input().split())
if len(set(a)) == len(a):
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import numpy as np
from collections import defaultdict

n = int(input())
a = np.array(list(map(int, input().split())))

d = defaultdict(int)

for i in range(n):
    d[a[i]] += 1

print("Yes") if max(d.values()) == 1 else print("No")

import numpy as np
from collections import defaultdict

n = int(input())
a = np.array(list(map(int, input().split())))

d = defaultdict(int)

for i in range(n):
    d[a[i]] += 1

print("YES") if max(d.values()) == 1 else print("NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n = int(input())
num = input().split()

def check():
  for s in num:
    if(num.count(s) >= 2):
      print("No")
      return
  print("Yes")

check()


n = int(input())
num = input().split()

if len(set(num)) == n:
  print("YES")
else:
  print("NO")


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import numpy as np

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

res = np.zeros(N)
for i in range(N):
  res[i] = (A==A[i]).sum()

if (res>1).sum() > 0:
  ans = 'NO'
else:
  ans = 'YES'
  
print(str(ans))

import numpy as np

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

A_uni = np.unique(A)
if len(A_uni) < N:
    ans = 'NO'
else:
    ans = 'YES'
print(str(ans))

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

for a in A:
    if b == a:
        print('No')
        exit()
    else:
        b = a
print('Yes')


N = int(input())
A = map(int, input().split())
A = sorted(A)
b = 0

for a in A:
    if b == a:
        print('NO')
        exit()
    else:
        b = a
print('YES')


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n,k = map(int,input().split())
p = list(map(int,input().split()))
ans = 0
for i in range(n-k+1):
    x = 0
    for j in p[i:i+k]:
        z = 0
        for a in range(1,j+1):
            z+=a*(1/j)
        x+=z
    ans = max(x,ans)
print(ans)

n = int(input())
a = input().split()
if n == len(set(a)):
  print("YES")
else:
  print("NO")

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N=input()
An = input()
list_An=[]
a = 0
for i in range(len(An)):
    if An[i]==" ":
        list_An.append(An[a:i])
        a = i
list_An.append(An[a+1:len(An)])
A =0
for i in range(len(list_An)):
    for j in range(len(list_An)):
        if list_An[i]==list_An[j]:
            A+=1
if A == len(list_An)+2:
    print("YES")
else:
    print("NO")

N=input()
An = input()
list_An=[]
a = 0
for i in range(len(An)):
    if An[i]==" ":
        list_An.append(int(An[a:i]))
        a = i+1
list_An.append(int(An[a:len(An)]))
list_An.sort()
A = 0
print(list_An)
for i in range(len(list_An)):
    if list_An[i-1]==list_An[i]:
        print("NO")
        A = 1
        break    
if A == 0:
    print("YES")


N=input()
An = input()
list_An=[]
a = 0
for i in range(len(An)):
    if An[i]==" ":
        list_An.append(int(An[a:i]))
        a = i+1
list_An.append(int(An[a:len(An)]))
A =0
print(list_An)
for i in range(len(list_An)):
    for j in range(len(list_An)):
        if list_An[i]-list_An[j]==0:
            A+=1
if A == len(list_An):
    print("YES")
else:
    print("NO")

N=input()
An = input()
list_An=[]
a = 0
for i in range(len(An)):
    if An[i]==" ":
        list_An.append(int(An[a:i]))
        a = i+1
list_An.append(int(An[a:len(An)]))
list_An.sort()
A = 0
for i in range(len(list_An)):
    if list_An[i-1]==list_An[i]:
        print("NO")
        A = 1
        break    
if A == 0:
    print("YES")


Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
# -*- coding: utf-8 -*-

# Input
s = [input() for i in range(2)]
N = int(s[0])
As = sorted(list(s[1].split()))

# Proccess
for i in range(0,N-1):
	if As[i] == As[i+1]:
		Anser = "No"
		break
	else:
		Anser = "Yes"
		
# Output							
print(Anser)

# -*- coding: utf-8 -*-

# Input
s = [input() for i in range(2)]
N = int(s[0])
As = sorted(list(s[1].split()))

# Proccess
for i in range(N):
	if As[i] == As[i+1]:
		Anser = "No"
		break
	else:
		Anser = "Yes"
		
# Output							
print(Anser)

# -*- coding: utf-8 -*-

# Input
s = [input() for i in range(2)]
N = int(s[0])
As = sorted(list(s[1].split()))

# Proccess
for i in range(0,N):
	if As[i] == As[i+1]:
		Anser = "No"
		break
	else:
		Anser = "Yes"
		
# Output							
print(Anser)

# C - Distinct or Not
N = int(input())
A = list(map(int, input().split()))

M = len(set(A))

if N == M:
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
List = sort(list(map(int, input().split())))
for i in range (N):
  for j in range (i+1, N):
    if List[j] == List[i]:
      print("NO")
      break
  else:
    continue
  break
else:
  print("YES")

N = int(input())
List = sorted(list(map(int, input().split())))
for i in range(N):
  if List[i] == List[i + 1]:
    print("NO")
    break
else:
  print("YES")

N = int(input())
List = sorted(list(map(int, input().split())))
for i in range(N-1):
  if List[i] == List[i + 1]:
    print("NO")
    break
else:
  print("YES")

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
A = list(map(int,input().split()))
b = list(set(A))
if b == A: print ('YES')
else: print ('NO')

N = int(input())
A = list(map(int,input().split()))
B = set(A)
if len(B) == len(A): print ('YES')
else: print ('NO')


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N=int(input())
a=set(list(map(int,input().split())))
if len(a)==N:
    print('Yes')
else:
    print('No')


N=int(input())
a=set(list(map(int,input().split())))
if len(a)==N:
    print('YES')
else:
    print('NO')


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

if len(set(A)) == N:
  print('Yes')
else:
  print('No')

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

if len(set(A)) == N:
  print('YES')
else:
  print('NO')

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import collections

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

c=collections.Counter(a)

ans=True
for i,m in c.items():
    if m>1:
        ans=False
        break
if ans:
    print("Yes")
else:
    print("No")

import collections

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

c=collections.Counter(a)

ans=True
for i,m in c.items():
    if m>1:
        ans=False
        break
if ans:
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

list_2 = list(set(list_1))

list_1.sort()

if list_1 == list_2:
    print('Yes')
else:
    print('No')

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

num = len(list_1)
num_2 = len(set(list_1))

if num == num_2:
    print('Yes')
else:
    print('No')

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


num_2 = len(set(list_1))

if N == num_2:
    print('YES')
else:
    print('NO')

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
A = [int(x) for x in input().split()]
for i in A:
    try:
        if A[i] == A[i+1]-1:
            print("YES")
        else:
            print("NO")
    except:
        pass


N = int(input())
A = list(map(int, input().split()))
S = set(A)
if len(S)==len(A):
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
input()
a = input().split()

x = {}
for i in a:
	if x.get(i, False):
		print("No")
		break
    x[i] = True
else:
	print("Yes")

input()
a = input().split()

ans = "Yes"
x = {}
for i in a:
    if x.get(i, False):
        ans = "No"
        break
    x[i] = True

print(ans)


input()
a = input().split()

x = {}
for i in a:
    if x.get(i, False):
        print("No")
        break
    x[i] = True
else:
    print("Yes")


input()
a = input().split()

x = {}
for i in a:
    if x.get(i, False):
        print("No")
        break
    x[i] = True
else:
    print("Yes")


input()
a = input().split()

x = {}
for i in a:
	if x.get(i, False):
		print("No")
		break
    x[i] = True
else:
	print("Yes")


input()
a = input().split()

ans = "YES"
x = {}
for i in a:
    if x.get(i, False):
        ans = "NO"
        break
    x[i] = True

print(ans)


Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n,*a = map(int, open(0).read().split())

def has_duplicates(seq):
    return len(seq) != len(set(seq))

if has_duplicates(a) == True:
  print("YES")
else:
  print("NO")

n,*a = map(int, open(0).read().split())

def has_duplicates(seq):
    return len(seq) != len(set(seq))

if has_duplicates(a) == True:
  print("NO")
else:
  print("YES")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
def has_duplicates(seq):
    if len(seq) == len(set(seq)):
        print("Yes")
    else:
        print("No")
    
N = int(input())
A = list(map(int,input().split()))
has_duplicates(A)


def has_duplicates(seq):
    if len(seq) == len(set(seq)):
        print("YES")
    else:
        print("NO")
    
N = int(input())
A = list(map(int,input().split()))
has_duplicates(A)




Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import sys
n=int(input())
a = [int(i) for i in input().split()]
for i in range(len(a)-1):
    for j in range(i+1,len(a)):
        if a[i]==a[j]:
            print('Yes')
            sys.exit()
print('No')

n=int(input())
a = [int(i) for i in input().split()]
if len(a)==len(set(a)):
    print('YES')
else:
    print('NO')

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

match = False
for i in range(1, N):
    if A[i] == A[i-1]:
        match = True
        break

if not match:
    print("Yes")
else:
    print("No")

N = int(input())

A = []
ans = True
for i in input().split():
    if int(i) in A:
        ans = False
        break
    else:
        A.append(int(i))

if ans:
    print("Yes")
else:
    print("No")

N = int(input())
A = sorted([int(i) for i in input().split()])

match = False
for i in range(1, N):
    if A[i] == A[i-1]:
        match = True
        break

if not match:
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

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

S=set(L)

if n==len(S):
	print('Yes')

else:
	print('NO')

n = int(input())

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

S=set(L)

if n==len(S):
	print('YES')

else:
	print('NO')

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

A_set = set(A_list)
A_set_len = len(A_set)

if int(A_list_len) == int(A_set_len):
    print('Yes')
else:
    print('No')

N = int(input())
A_list = list(map(int, input().split()))
A_list_len = len(A_list)

A_set = set(A_list)
A_set_len = len(A_set)

if A_list_len == A_set_len:
    print('Yes')
else:
    print('No')

N = int(input())
A_list = list(map(int, input().split()))
A_list_len = len(A_list)

A_set = set(A_list)
A_set_len = len(A_set)

if A_list_len == A_set_len:
    print('Yes')
else:
    print('No')

N = int(input())
A_list = list(map(int, input().split()))
A_list_len = len(A_list)

A_set = set(A_list)
A_set_len = len(A_set)

if int(A_list_len) == int(A_set_len):
    print('YES')
else:
    print('NO')

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n = int(input())
if n = len(set(input().split())):
    print('YES')
else:
    print('NO')

n = int(input())
if n == len(set(input().split())):
    print('YES')
else:
    print('NO')

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
A = input().split()
A.sort()
frag = None
for i in range(N-1):
  if A[i] ==A[i+1]:
    print('NO')
    frag = 1
    break
if frag == None:
  print('Yes')


N = int(input())
A = input().split()
A.sort()
frag = None
for i in range(N-1):
  if A[i] ==A[i+1]:
    print('NO')
    frag = 1
    break
if frag == None:
  print('YES')


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

def main():
    new_A = sorted(A)

    for i in range(S-1):
        if new_A[i] == new_A[i+1]:
            flag = 1
            break
        else:
            continue
        
    if flag == 0:
        print('YES')
    else:
        print('NO')


if __name__ == "__main__":
    main()
    

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

def main():
    flag = 0
    new_A = sorted(A)

    for i in range(S-1):
        if new_A[i] == new_A[i+1]:
            flag = 1
            break
        else:
            continue

    if flag == 0:
        print('YES')
    else:
        print('NO')


if __name__ == "__main__":
    main()
    

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import heapq

N = int(input())
A = list(int(x) for x in input().split())
heapq.heapify(A)
com1 = heapq.heappop(A)
ans = True

for _ in range(N-1):
    com2 = heapq.heappop(A)

    if com1 == com2:
        ans = False
        break

    com1 = com2

if ans:
    print('Yes')
else:
    print('No')


import heapq

N = int(input())
A = list(int(x) for x in input().split())
heapq.heapify(A)
com1 = heapq.heappop(A)
ans = True

for _ in range(N-1):
    com2 = heapq.heappop(A)

    if com1 == com2:
        ans = False
        break

    com1 = com2

if ans:
    print('YES')
else:
    print('NO')


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
A = [int(x) for x in input().split()]
A.sort()
for i in range(1, len(A)):
    if A[i - 1] != A[i]:
        continue
        k = True
    else:
        k = False
        break

if k:
    print("Yes")
else:
    print("No")

from collections import Counter
N = int(input())
A = [int(x) for x in input().split()]

k = Counter(A)

if len(k) == len(A):
    print("Yes")
else:
    print("No")

N = int(input())
A = [int(x) for x in input().split()]
A.sort()
for i in range(1, len(A)):
    if A[i - 1] != A[i]:
        k = True
    else:
        k = False
        break

if k:
    print("Yes")
else:
    print("No")

N = int(input())
A = [int(x) for x in input().split()]
A.sort()
for i in range(1, len(A)):
    if A[i - 1] != A[i]:
        k = True
    else:
        k = False
        break

if k:
    print("YES")
else:
    print("NO")

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n=int(input())
l=list(map(int,input().split()))
m=set(l)
if len(l)==len(m):
    print("Yes")
else:
    print("No")


n=int(input())
l=list(map(int,input().split()))
m=set(l)
if len(l)==len(m):
    print("YES")
else:
    print("NO")


Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
def main():
    N = int(input())
    A = list(map(int,input().split()))
    B = set(A)
    C = len(B)
    if N == len(set(A)):
        print("Yes")
    else:
        print("No")
    
    
    

main()

def main():
    N = int(input())
    A = list(map(int,input().split()))
    #B = set(A)
    
    if N == len(set(A)):
        print("YES")
    else:
        print("NO")
    
    
    

main()

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

numlist.sort()
for i in range(N-1):
    if numlist[i] == numlist[i+1]:
        print('No')
        sys.exit()

print('Yes')


import sys
N = int(input())
numlist = list(map(int, input().split()))

numlist.sort()
for i in range(N-1):
    if numlist[i] == numlist[i+1]:
        print('No')
        sys.exit()

print('Yes')


import sys
N = input()
numlist = list(map(int, input().split()))

for i in range(N):
  if numlist[0] == numlist[i]:
    print('No')
    sys.exit()

print('Yes')

import sys
N = int(input())
numlist = list(map(int, input().split()))

numlist.sort()
for i in range(N-1):
    if numlist[i] == numlist[i+1]:
        print('NO')
        sys.exit()

print('YES')


Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

for x in range(n-1):
  if an[i+1]-an[i] == 0:
    print("NO")
    break

else:
  print("YES")
  

n = int(input())
an = list(map(int,input().split()))
an.sort()

for x in range(n-1):
  if an[x+1]-an[x] == 0:
    print("NO")
    break

else:
  print("YES")
  

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
n=int(input())
li=list(map(int, input().split()))
ans="Yes"
for i in range(n):
  for j in range(i+1, n):
    if li[i]==li[j]:
      ans="No"
      break
  else:
    continue
  break
print(ans)

n=int(input())
li=list(map(int, input().split()))
if n==len(set(li)):
  print("YES")
else:
  print("NO")

Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
N = int(input())
A = list(map(int, input().split()))
cnt = 0
from collections import Counter

if A.most_common[0][1] <= 1:
	print('YES')
else:
	print('NO')

N = int(input())
A = list(map(int, input().split()))
cnt = 0
from collections import Counter
B=A.Counter
if B.most_common[0][1] <= 1:
	print('YES')
else:
	print('NO')

N = int(input())
A = list(map(int, input().split()))
cnt = 0
from collections import Counter
B=Counter(A)
C=B.most_common()
if C[0][1] <= 1:
	print('YES')
else:
	print('NO')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

flag=0
for i in range(N):
	count=0
	for j in range(N):
		if a[i]==a[j] and i!=j:
			count+=1
			print("No")
			flag+=count
			break
		else:
			continue
	if count>=1:
		break
if flag==0:
	print("Yes")

# coding: utf-8
# Your code here!
n=int(input())
s=set(input().split())
if len(s)==n:
    print("YES")
else:
    print("NO")

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

count = 0

for i in range(a):
    # if li[-1] == li[i]:
    #     continue
    if i == a-1:
        continue
    else:
        if li[-5] == li[i]:
            count += 1
    for j in li[i+1:]:
        if li[i] == j:
            count += 1
        else:
            pass

if count > 0:
    print('NO')
else:
    print("YES")

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

is_break = False
seen = set()
for a in A:
    if a not in seen:
        seen.add(a)
    else:
        is_break=True
        break

if is_break:
    print('NO')
else:
    print('YES')

Verdicts: Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import sys
n = int(input())
a = sorted(list(map(lambda x: int(x),input().split())))
for i in range(n - 1):
    if a[i] == a[i+1] :
        print('NO')
        sys.exit()
print('Yes')


n = int(input())
a = sorted(list(map(lambda x: int(x),input().split())))
flag = 0
for i in range(n - 1):
    if a[i] == a[i+1] :
        print('NO')
        flag = 1
        break

if flag == 0 :
    print('Yes')


n = int(input())
a = sorted(list(map(lambda x: int(x),input().split())))

for i in range(n - 1):
    if a[i] == a[i+1] :
        print('NO')
        flag = 1
        break
    flag = 0

if flag == 0 :
    print('Yes')

import sys
n = int(input())
a = sorted(list(map(lambda x: int(x),input().split())))
for i in range(n - 1):
    if a[i] == a[i+1] :
        print('NO')
        sys.exit()
print('YES')

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
import sys
import collections

N = int(input())
A_i = list(map(int, input().split()))
A_i = [i for i in A_i if 1 <= i and i <= 10**9]

if not 2 <= N or not N <= 2*10**5:
    print("error:N")
    sys.exit()
if len(A_i) != N:
    print("error")
    sys.exit()

if len(collections.Counter(A_i)) == len(A_i):
    print("Yes")
else:
    print("No")

import sys
import collections

N = int(input())
A_i = list(map(int, input().split()))
A_i = [i for i in A_i if 1 <= i and i <= 10**9]

if not 2 <= N or not N <= 2*10**5:
    print("error:N")
    sys.exit()


if len(collections.Counter(A_i)) == len(A_i):
    print("Yes")
else:
    print("No")

import sys

N = int(input())
A_i = list(map(int, input().split()))
A_i = [i for i in A_i if 1 <= i and i <= 10**9]

if not 2 <= N or not N <= 2*10**5:
    print("error:N")
    sys.exit()
if len(A_i) != N:
    print("error")
    sys.exit()

if len(list(set(A_i))) == len(A_i):
    print("Yes")
else:
    print("No")

import sys

N = int(input())
A_i = list(map(int, input().split()))
A_i = [i for i in A_i if 1 <= i and i <= 10**9]

if not 2 <= N or not N <= 2*10**5:
    print("error:N")
    sys.exit()
if len(A_i) != N:
    print("error")
    sys.exit()

if len(list(set(A_i))) == len(A_i):
    print("YES")
else:
    print("NO")

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
stdin = open(0).read().split('\n')
N = int(stdin[0])
A = list(map(int,stdin[1].split()))
B = set(A)
print('Yes' if len(A)==len(B) else'No')

stdin = open(0).read().split('\n')
N = int(stdin[0])
A = list(map(int,stdin[1].split()))
print('Yes' if len(A)==len(B) else'No')

stdin = open(0).read().split('\n')
N = int(stdin[0])
A = list(map(int,stdin[1].split()))
B = set(A)
print('YES' if len(A)==len(B) else 'NO')

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

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

def dup(seq):
    return len(seq) != len(set(seq))

if(dup(li)): 
    print("No")
else:
     print("Yes")




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

def dup(seq):
    return len(seq) != len(set(seq))

if(dup(li)): 
    print("NO")
else:
     print("YES")




Verdicts: Wrong Answer

Accepted
Problem: Given is a sequence of integers A_1, A_2, ..., A_N. If its elements are pairwise distinct, print `YES`; otherwise, print `NO`.

Submission attempts (in order):
#include <bits/stdc++.h>
using namespace std;

int main()
{
  int n;
  bool ans = 1;
  cin >> n;
  vector<int> vec(n);
  for (int i = 0; i < n; i++)
    cin >> vec[i];
  sort(vec.begin(), vec.end());

  for (int i = 0; i < n - 1; i++)
  {
    if (vec[i] == vec[i + 1])
    {
      ans = 0;
      break;
    }
  }
  if (ans)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
}

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

if (len(set(A)) == len(A)):
  print("YES")
else:
  print("NO")


Verdicts: Runtime Error

Accepted