TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
a = int(input())
str = list(input())

if a%2 :
	print("No")
	exit()
  
n_str_1 = ""
n_str_2 = ""
  
fot i in range(a/2):
	n_str_1 += str[i]
    n_str_2 += str[i+a/2]

if n_str_1 == n_str_2 :
	print("Yes")
else :
  	print("No")

a = int(input())
s = list(input())

n_s_1 = []
n_s_2 = []

if a%2 :
    print("No")
    exit()

for i in range(int(a/2)):
    n_s_1 += s[i]
    n_s_2 += s[i + int(a/2)]

if n_s_1 == n_s_2:
    print("Yes")
else :
    print("No")

Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N=int(input())
S=input()
if N%2==1:
    print("No")
elif N==2:
    T1=S[0]
    T2=S[1]
else:
    T1=S[0:(N//2)]
    T2=S[N//2:(N)]
print(T1,T2)
if S==T1+T2:
    print("Yes")
else:
    print("No")

N=int(input())
S=input()

if N%2==0 and S[0:N//2]==S[N//2:N]:
    print("Yes")
else:
    print("No")


Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
s=str(input())
flag=0
if len(s)%2==0:
  n=len(s)//2
  for i in range(n):
    if s[i]!=s[n+i]:
      flag=1
else:
  flag=1
if flag==0:
  print('Yes')
else:
  print("No")

x=int(input())
s=str(input())
flag=0
if len(s)%2==0:
  n=len(s)//2
  for i in range(n):
    if s[i]!=s[n+i]:
      flag=1
else:
  flag=1
if flag==0:
  print('Yes')
else:
  print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if n % 2 == 1:
    print("No")
else:
    s_1 = s[:n/2]
    s_2 = s[n/2:n]
    if s_1 != s_2:
        print("No")
    else:
        print("Yes")

n = int(input())
s = input()

if n % 2 == 1:
    print("No")
else:
    if s[:n/2] != s[n/2:n]:
        print("No")
    else:
        print("Yes")

n = int(input())
s = input()

if n % 2 == 1:
    print("No")
else:
    c = int(n/2)
    s_1 = s[:c]
    s_2 = s[c:n]

    if s_1 != s_2:
        print("No")
    else:
        print("Yes")

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
def f():
    n = int(input())
    s = input()
    if n%2:
        return "NO"
    else:
        half = n//2
        for i in range(half):
            if s[i] != s[i+half]:
                return "NO"
        return "YES"

print(f())

def f():
    n = int(input())
    s = input()
    if n%2:
        return "No"
    else:
        half = n//2
        for i in range(half):
            if s[i] != s[i+half]:
                return "No"
        return "Yes"

print(f())


Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N,S=int(input()),input()
a,b='',''
if N%2==0:
    for i in range(int(N/2)):
        a = a+S[i]
        b = S[len(S)-(i+1)]+b
    print('Yes' if a==b else: 'No')
else:
    print(No)

N,S=int(input()),input()
a,b='',''
if N%2==0:
    for i in range(int(N/2)):
        a = a+S[i]
        b = S[len(S)-1]+b
    print('Yes' if a==b else: 'No')
else:
    print(No)

N,S=int(input()),input()
a,b='',''
if N%2==0:
    for i in range(int(N/2)):
        a = a+S[i]
        b = S[len(S)-(i+1)]+b
    print('Yes' if a==b else 'No')
else:
    print('No')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if n % 2 == 1:
    print('No')
else:
    flg=True
    for i in range(int(n/2)):
        if S[i]!=S[int(n/2)+i]:
            flg=False
    if flg==True:
        print('Yes')
    else:
        print('No'):
  

N=int(input())
S=str(input())
if N%2==1:
  print('No')
else:
  f=True
  h=int(N/2)
  if S[0:h-1]==S[h:N]:
    print('Yes')
  else:
    print('No')

N=int(input())
S=input()
if N%2==1:
  print('No')
else:
  h_N=int(N/2)
  flg=True
  for i in range(h_N):
    if S[i]!=S[h_N+i]:
      flg=False
  if flg=True:
    print('Yes')
  else:
    print('No')

N=int(input())
S=str(input())
if N%2==1:
  print('No')
else:
  f=True
  h=int(N/2)
  for i in range(0,h):
    if S[i]!=S[h+i]:
      f=False
  if f==True:
    print('Yes')
  else:
    print('No')


Verdicts: Runtime Error

Wrong Answer

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
l = int(input())
words = input()

if l % 2 != 0:
    exit()

m = int(len(words) /2)
print(m)
first = words[0:m]
last = words[m:]
if first == last:
    print('Yes')
else:
    print('No')


l = int(input())
words = input()

if l % 2 != 0:
    print('No')
    exit()

m = int(len(words) /2)
first = words[0:m]
last = words[m:]
if first == last:
    print('Yes')
else:
    print('No')

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
s = input()
ans = s[0:int(len(s)/2)]
if 2*ans == s:
    print('Yes')
else:
    print('No')

n = int(input())
s = input()
ans = s[0:int(len(s)/2)]
if 2*ans == s:
    print('Yes')
else:
    print('No')

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

result = "yes"
n= int(N/2)
if(N%2 == 0):
    for i in range(n):
        if(S[i] != S[n+i]):
            result = "no"
else:
    result = "no"
print(result)

N = int(input())
S = str(input())

result = "Yes"
n= int(N/2)
if(N%2 == 0):
    for i in range(n):
        if(S[i] != S[n+i]):
            result = "No"
else:
    result = "No"
print(result)

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

t = s[:n//2 - 1]
if n % 2 == 0:
    # flg = t in s[n//2:]
    if t == s[n//2:]:
        print("Yes")
    else:
        print("No")
else:
    print("No")

n = int(input())
s = input()

t = s[:n//2]
if n % 2 == 0:
    flg = t in s[n//2:]
    if flg:
        print("Yes")
    else:
        print("No")
else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n=int(input())
s=input()
if type(n/2)=='int':
    if s[0:n/2]=s[n/2:n]:
        print('Yes')
    else:
        print('No')
else:
    print('No')

n=int(input())
s=input()
a=(s[0:int(n/2)])
b=(s[int(n/2):n])
if n%2==0:
    if a==b:
        print('Yes') 
    else:
        print('No')
else:
    print('No')

Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if N % 2 == 0 and S[:N] == S[N:]:
    print("Yes")
else:
    print("No")

N = int(input())
S = input()

if N % 2 == 0 and S[:N//2] == S[N//2:]:
    print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N=int(input())
S=input()
ans=0
if N%2==0:
  for i in range(N/2):
    if S[i]==S[i+N/2]:
      ans+=1
if ans==N/2:
  print('Yes')
else:
  print('No')

N=int(input())
S=input()
ans=0
if N%2==0:
  for i in range(N/2):
    if S[i]==S[i+(N/2)]:
      ans+=1
if ans==N/2:
  print('Yes')
else:
  print('No')

N=int(input())
S=input()
ans=0
if N%2==0:
  for i in range(N//2):
    if S[i]==S[i+(N//2)]:
      ans+=1
if ans==N/2:
  print('Yes')
else:
  print('No')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if s[:n-1] == s[n-1:]:
    print("Yes")
else:
    print("No")

n = int(input())
s = input()


if s[:n//2] == s[n//2:]:
    print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input())
S = input()
H = list(S)
P = len(H)
oo = []
ll = []
if P/2 == 0:
  for a in range (0,N/2):
    oo.append(a)
    ll.append(a+N/2)
    if oo == ll :
      print("Yes")
else :
  print("No")
    
 
    

  


N = int(input())
S = input()
H = list(S)
P = len(H)
oo = []
ll = []
if P%2 == 0:
  for a in range (0,N/2):
    oo.append(H(a))
    ll.append(H(a+N/2))
    if oo == ll :
      print("Yes")
else :
  print("No")
    
 
    

  


N = int(input())
S = input()
H = list(S)
P = len(H)
oo = []
ll = []
if P%2 == 0:
  for a in range (0,N/2):
    oo.append(a)
    ll.append(a+N/2)
    if oo == ll :
      print("Yes")
else :
  print("No")
    
 
    

  


N = int(input())
S = input()
H = list(S)
P = len(H)
oo = []
ll = []
if P%2 == 0:
  for a in range (0,int(N/2)):
    oo.append(H[int(a)])
    ll.append(H[int(a+N/2)])
  if oo == ll :
    print("Yes")
  else :
    print("No")
else :
  print("No")
    
 
    

  


Verdicts: Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
import sys
n=int(input())
s = list(input())
ans = 0
if n % 2 != 0:
    print("No")
    sys.exit()
for i in range(n//2 - 1):
    if s[i] != s[i+n//2+1]:
        ans = 1
if ans == 0:
    print("Yes")
else:
    print("No")

import sys
n=int(input())
s = list(input())
ans = 0
if n % 2 != 0:
    print("No")
    sys.exit()
for i in range(n//2 ):
    if s[i] != s[i+n//2]:
        ans = 1
if ans == 0:
    print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input())
str = input()
if len(str) % 2 != 0:
  print("No")
elif str[:int(len(str)/2)] != str[int(len(str)/2) + 1:]:
  print("No")
else:
  print("Yes")

N = int(input())
str = input()
if len(str) % 2 != 0:
  print("No")
elif str[:int(len(str)/2)] != str[int(len(str)/2):]:
  print("No")
else:
  print("Yes")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n=int(input())
s=input()
if s[:(n//2)]＊2==s:
  print("Yes")
else:
  print("No")

N=int(input())
S=input()
if S[:(N//2)]==S:
  print("Yes")
else:
  print("No")

N=int(input())
S=input()
if S[:(N//2)]*2==S:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if S%2==1:
  print('No');exit()
  
print('Yes' if S[0:S//2-1]==S[S//2-1:N-1] else 'No')

N=int(input())
S=str(input())
 
if N%2==1:
  print('No');exit()
  
print('Yes' if S[0:N//2]==S[N//2:N] else 'No')

Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
listnum = int(input())
string = input()

halfnum = listnum / 2
halfstr = string[0:halfnum]
if string == halfstr + halfstr:
	print('Yes')
else:
	print('No')

listnum = int(input())
string = input()

halfnum = listnum // 2
halfstr = string[0:halfnum]
if string == halfstr + halfstr:
	print('Yes')
else:
	print('No')

Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if n % 2 == 0:
    t = s[0:n/2]
    if s == t + t:
        print("Yes")
        exit()
print("No")
    

n = int(input())
s = input()

if n % 2 == 0:
    t = s[0:int(n/2)]
    if s == t + t:
        print("Yes")
        exit()
print("No")

Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n=int(input())
s=str(input())
r=s[:n//2]
t=s[n//2:]
print(r)
print(t)
if(r==t):
  print("Yes")
else:
  print("No")


n=int(input())
s=str(input())
if(n%2==0):
  r=s[:(n/2)]
  t=s[(n/2):]
  if(r==t):
    print("Yes")
  else:
    print("No")
    
else:
  print("No")

n=int(input())
s=str(input())
r=s[:(n/2)]
t=s[(n/2):]
if(r==t):
  print("Yes")
else:
  print("No")


n=int(input())
s=str(input())
r=s[:n//2]
t=s[n//2:]
if(r==t):
  print("Yes")
else:
  print("No")


Verdicts: Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input())
S = str(input())
num =int( N / 2)

f = S[0:num]

if S == f+f:
    print('YES')
else:
    print('NO')


N = int(input())
S = str(input())

if N % 2 != 0:
    print('NO')
else:
    num =int( N / 2)
    f = S[0:num]
    if S == f+f:
        print('YES')
    else:
        print('NO')

N = int(input())
S = str(input())
if S[:N//2] == S[N//2:]:
    print('YES')
else:
    print('NO')

N = int(input())
S = input()
if S[:N//2] == S[N//2:]:
    print("Yes")
else:
    print("No")


Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n = int(input())
s = input()
if n % 2 != 0:
  print("No")
else:
  T = s[0:n//2+1]
  if T + T == s:
    print("Yes")
  else:
    print("No")


n = int(input())
s = input()
t = s[0:n//2]
if s = t+t:
  print("Yes")
else:
  print("No")

n = int(input())
s = input()
if n % 2 != 0:
  print("Yes")
else:
  T = s[0:n//2+1]
  if T + T == s:
    print("Yes")
  else:
    print("No")

n = int(input())
s = input()
t = s[0:n//2]
if s == t+t:
  print("Yes")
else:
  print("No")


Verdicts: Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
t = int(input())
s = input()
if(s[0:t//2]==s[t//2:t]:
   print("Yes")
else:
   print("No")

t = int(input())
s = input()
if(s[0:t//2]==s[t//2:t]):
   print("Yes")
else:
   print("No")

Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n,s=open(0);n=int(n);print("YNeos"[s!=s[:n//2]*2::2])

n,s=open(0);print("YNeos"[s[:-1]!=s[:int(n)//2]*2::2])

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
s = input()

if len(s) % 2 != 0:
  print('No')
else:
  s1 = s[:len(s)//2]
  s2 = s[len(s)//2:]
 
  if s1 == s2:
    print('Yes')
  else:
    print('No')

i = input()
s = input()

if len(s) % 2 != 0:
  print('No')
else:
  s1 = s[:len(s)//2]
  s2 = s[len(s)//2:]
 
  if s1 == s2:
    print('Yes')
  else:
    print('No')

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if s[:n] == s[n:]:
  print('Yes')
else:
  print('No')

n = int(input())
s = input()
 
if n % 2 != 0:
  print('No')
else:
  if s[:int(n/2)] == s[int(n/2):]:
    print('Yes')
  else:
    print('No')

  

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input())
if N % 2 == 1:
    print("No")
	exit()
S = input()
if S[0:N//2] == S[N//2:]:
    print("Yes")
else:
    print("No")


N = int(input())
if N % 2 == 1:
    print("No")
    exit()
S = input()
if S[0:N//2] == S[N//2:]:
    print("Yes")
else:
    print("No")


Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n = int(input())
b = n/2
a = input()
if n%2 == 1:
  print("No")
else:
	if a[0:int(n/2)-1]==a[int(n/2):n-1]:
  		print("yes")
	else:
  		print("No")

n = int(input())
a = input()
if a[0:int(n/2)]==a[int(n/2):n]:
	print("Yes")
else:
	print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n = int(input())//2
s = input()
print('yes' if s[:n] == s[n:] else 'no')

n = int(input())//2
s = input()
print('Yes' if s[:n] == s[n:] else 'No')

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
S = input().strip()
q, r = divmod(len(S), 2)
if r == 0 and S[:q] == S[q:]:
  print('Yes')
else:
  print('No')

n, S = open(0).read().split()
q, r = divmod(int(n), 2)
if r == 0 and S[:q] == S[q:]:
  print('Yes')
else:
  print('No')

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N=int(input())
S=input()
if N%2 !=0:
  print("No")
elif S[:N/2]==S[N/2:]:
  print("Yes")
else:
  print("No")

N=int(input())
S=input()
X=int(N/2)
T=S[:X]+S[:X]
if N%2 !=0:
  print("No")
elif S==T:
  print("Yes")
else:
  print("No")


Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n = int(input())
s = input()
# print(s[:n // 2], s[n//2+1:n])
if n % 2 == 1 :
    print("NO")
elif s[:n // 2] == s[n//2:n]:
    print("YES" )
else:
    print("NO")

n = int(input())
s = input()
# print(s[:n // 2], s[n//2+1:n])
if n % 2 == 1 :
    print("No")
elif s[:n // 2] == s[n//2:n]:
    print("Yes" )
else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N=int(input())
S=input()
if N%2!=0:
    print('No')
	exit()
    
if S[0:N//2]==S[N//2:N]:
	print('Yes')
else:
	print('No')

N=int(input())
S=input()
if N%2!=0:
    print('No')
    exit()
    
if S[0:N//2]==S[N//2:N]:
    print('Yes')
else:
    print('No')

Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n=  input()
s= input()
if n+n==s:
  print('Yes')
else:
  print('No')

n = int(input())
s = input()
if n%2!=0:
    print('No')
else:
    t = s[:n//2]
    if t+t==s:
        print('Yes')
    else:
        print('No')


Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N=int(input())
S=input()
len_of_s=len(S)
if len_of_s%2==0 and S[:len_of_s/2]==s[len_of_s/2:]:
  print("Yes")
elif:
  print("No")

N=int(input())
S=input()
len_of_s=len(S)
if len_of_s%2==0 and S[:len_of_s/2+1]==s[len_of_s/2+1:]:
  print("Yes")
elif
  print("No")

N=int(input())
S=input()
len_of_s=len(S)
if len_of_s%2==0 and S[:len_of_s//2]==S[len_of_s//2:]:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if n == 1:
    print('Yes')
else:
    if n % 2 == 0:
        head = s[:n // 2]
        tail = s[n // 2:]
    else:
        head = s[:n // 2]
        tail = s[n // 2 + 1:]

    print(head)
    print(tail)
    if head == tail:
        print('Yes')
    else:
        print('No')


n = int(input())
s = input()

if n % 2 == 1:
    print('No')
else:
    head = s[:n // 2]
    tail = s[n // 2:]

    if head == tail:
        print('Yes')
    else:
        print('No')


Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
##B
n = int(input())
s = str(input())

n1 = int(n/2)

print(s[0:n1]+s[n1:n])

if s == s[0:n1]+s[n1:n] and n % 2 == 0:
    print("Yes")
else:
    print("No")

##B
n = int(input())
s = str(input())

n1 = int(n/2)

if s == s[0:n1]+s[0:n1] and n % 2 == 0:
    print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if print(s[0:n//2]) == print(s[n//2:]):
  print('Yes')
else:
  print('No')



n = int(input())
s = input()

if s[0:n//2] == s[n//2:]:
  print('Yes')
else:
  print('No')



Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
s = input()
if len(S) % 2 == 1:
  print('No')
else:
  if s[0:(len(s)-1)/2] == s[(len(s)-1)/2+1:len(s)-1]:
    print('Yes')
  else:
    print('No')

n = int(input())
s = input()
if n % 2 == 1:
  print('No')
else:
  if s[0:n//2-1] == s[n//2+1:n-1]:
    print('Yes')
  else:
    print('No')

n = int(input())
s = input()
if n % 2 == 1:
  print('No')
else:
  if s[0:n//2] == s[n//2:n]:
    print('Yes')
  else:
    print('No')

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n=int((int(input()))/2)
s=input()
if(n%2!=0):
	print("No")
elif(s[:n]==s[n:]):
	print("Yes")
else:
		print("No")
	



n=input()
if (len(n)%2==1):
	print("No")
else:
	if (n[0:len(n)//2] == n[len(n)//2:]):
		print("Yes")
	else:
		print("No")

n=int(input())
s=input()

if n%2==1:
  print("No")
else:
  k=n//2
  if(s[0:k]==s[k:n]):
    print("Yes")
  else:
    print("No")

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n=int(input())
s=input()
if len(s)%2==1:
  print('No')
else:
  i=len(s)/2
  j=i//1
  if s[:j]+s[:j]==s:
    print('Yes')

n=int(input())
s=input()
if len(s)%2==1:
  print('No')
else:
  i=len(s)/2//1
  if s[:i]*2==s:
    print(Yes)

n=int(input())
s=input()
if len(s)%2==1:
  print('No')
else:
  i=len(s)/2
  j=i//1
  if s[:j]+s[:j]==s:
    print(Yes)

n=int(input())
s=input()
if len(s)%2==1:
  print('No')
else:
  i=len(s)//2
  if s[:i]+s[:i]==s:
    print('Yes')
  else :
    print('No')

Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if n % 2 == 1:
  print("No")
else:
  t = n // 2
  if s[1:t] == s[t:n]:
    print("Yes")
  else:
    print("No")

n = int(input())
s = input()

if n % 2 == 1:
  print("No")
else:
  t = n // 2
  if s[0:t] == s[t:n]:
    print("Yes")
  else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
import sys
n = int(sys.stdin.readline())
s = sys.stdin.readline().strip()
if not n % 2:
  if s[0:n/2] == s[n/2:]:
    print('Yes')
  else:
    print('No')
else:
  print('No')

import sys
n = int(sys.stdin.readline())
s = sys.stdin.readline().strip()
if not n % 2:
  if s[0:n//2] == s[n//2:]:
    print('Yes')
  else:
    print('No')
else:
  print('No')


Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N=int(input())
S=input()
if N%2==0:
    print('No')
for i in range(N/2):
    if S[i]!=S[N/2+i]:
        print('No')
        exit()
print('Yes')

N=int(input())
S=input()
if N%2!=0:
    print('No')
for i in range(N/2):
    if S[i]!=S[N/2+i]:
        print('No')
        exit()
print('Yes')

N=int(input())
S=input()
if N%2!=0:
    print('No')
    exit()
for i in range(int(N/2)):
    if S[i]!=S[int(N/2)+i]:
        print('No')
        exit()
print('Yes')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input())
S = input().split()
X = S[:N//2+1]
if N%2 == 0 and X+X == S:
  print('Yes')
else:
  print('No')

  

N = int(input())
S = input()
X = S[:N//2]
if X+X == S:
  print('Yes')
else:
  print('No')

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
s = str(input())
n = len(s)
if n % 2 == 1:
    print("No")
    exit()
if s[:n // 2 + 1] == s[n // 2 + 1:]:
    print("Yes")
    exit()
print("No")

s = str(input())
n = len(s)
for i in range(n):
    for j in range(i):
            if s[j:i+1] in s[i+1:n]:
                print("Yes")
                exit()
print("No")

n = int(input())
s = str(input())
if n % 2 == 1:
    print("No")
    exit()
if s[:n // 2] == s[n // 2:]:
    print("Yes")
    exit()
print("No")

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n=int(input())
print(n**2)
#B
n=int(input())
s=list(str(input()))
if n % 2 ==0:
    ans=0
    for i in range(n//2):
        if s[i]==s[n//2+i]:
            ans+=1
        else:
            ans+=0

    if ans==n//2:
        print('Yes')
    else:
        print('No')   

else:
    print('No')

n=int(input())
s=list(str(input()))
if n % 2 ==0:
    ans=0
    for i in range(n//2):
        if s[i]==s[n//2+i]:
            ans+=1
        else:
            ans+=0

    if ans==n//2:
        print('Yes')
    else:
        print('No')   

else:
    print('No')


Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input())
S = input()
if S[0:N//2] == S[N//2:N]:
    print("yes")
    
elif S[0:N//2] != S[N//2:N]:
    print("No")

else:
    print("No")

N = int(input())
S = input()
if S[0:N//2] == S[N//2:N]:
    print("yes")
    
elif S[0:N//2] != S[N//2:N]
    print("No")

else:
    print("No")

N = int(input())
S = input()

if S[0:N//2] == S[N//2:N]:
    print("yes")
    
elif S[0:N//2] != S[N//2:N]:
    print("No")

else:
    ("No")

N = int(input())
S = input()
if S[0:N//2] == S[N//2:N]:
    print("yes")
    
elif S[0:N//2] != S[N//2:N]:
    print("No")

else:
    print("No")

N = int(input())
S = input()

if S[0:N//2]*2 == S:
       print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Runtime Error

Wrong Answer

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
a = int(input())
b = input()
if a%2 == 0:
  print("Yes" if a[:(a/2-1)] == a[(a/2):] else "No")
else:
  print("No")

a = int(input())
b = input()
if a%2 == 0:
  print("Yes" if a[:(a/2)] == a[(a/2):] else "No")
else:
  print("No")

a = int(input())
b = input()
if a%2 == 0:
  print("Yes" if b[:(a/2)] == b[(a/2):] else "No")
else:
  print("No")

a = int(input())
b = input()
if a%2 == 0:
  print("Yes" if b[:int(a/2)] == b[int(a/2):] else "No")
else:
  print("No")

Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N=input()
S=list(input())

if len(N)%2!=0:
  print('No')
else:
  if S[:N/2]==S[N/2]:
    print('Yes')
  else:
    print('No')

N=input()
S=list(input())
 
if N%2!=0:
    print('No')
else:
    if S[:N/2]==S[N/2:]:
        print('Yes')
    else:
        print('No')



N=int(input())
S=list(input())
 
if N%2!=0:
    print('No')
else:
    if S[:N//2]==S[N//2:]:
        print('Yes')
    else:
        print('No')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
n = int(input())
t = [i for i in input()]

if n % 2 == 1:
    print('NO')
else:
    if t[:int(n/2)] == t[int(n/2):]:
        print('YES')
    else:
        print('NO')

n = int(input())
t = [i for i in input()]

if n % 2 == 1:
    print('No')
else:
    if t[:int(n/2)] == t[int(n/2):]:
        print('Yes')
    else:
        print('No')

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input())
S = input()
 
if(N % 2 == 1):
    print("No")
nn = int(N / 2)
if(S[nn:] == S[:nn] and S[nn:] is S[:nn]):
    print("Yes")
else:
    print('No')

N = int(input())
S = input()
 
if(N % 2 == 1):
    print('No')
nn = int(N / 2)
if(S[nn:] is S[:nn]):
    print('Yes')
else:
    print('No')

N = int(input())
S = input()

if(N % 2 == 1):
    print("No")
nn = N / 2
if(S[nn:] == S[:nn]):
    print("Yes")
else:
    print('No')


N = int(input())
S = input()
 
if(N % 2 == 1):
    print("No")
    exit()
nn = int(N / 2)
if(S[nn:] != S[:nn]):
    print('No')
else:
    print("Yes")

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

b = a[0:n//2]
c = a[n//2-1:n-1]

#print(b)
#print(c)

if n!=1:
	if b==c :
		print('Yes')
	else:
		print('No')
else:
	print('No')



n = int(input())
a = input()

b = a[0:n//2]
c = a[n//2-1:n-1]

if b==c :
	print('Yes')
else:
	print('No')



n = int(input())
a = input()

b = a[0:n//2]
c = a[n//2:n]

#print(b)
#print(c)

if n!=1:
	if b==c :
		print('Yes')
	else:
		print('No')
else:
	print('No')



Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N=int()input()
S=input()
bit=0
for i in range(0,N):
  Check=S[0:i]
  Ans=S[i:N]
  if Check==Ans:
    bit+=1
print("Yes" if bit>=1 else "No")

N=int(input())
S=list(str(input()))

S_right=[]
S_left=[]
for i in range(0,(N//2)):
    S_left.append(S[i])
for i in range((N//2),N):
    S_right.append(S[i])
    
S_left=("").join(S_left)
S_right=("").join(S_right)

print("Yes" if S_left==S_right else "No")

Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if n%2 == 0:
    p = n//2
    print(S[:p],S[p:])
    if S[:p] == S[p:]:
        print("Yes")
    else:
        print("No")
else:
    print("No")

n = int(input())
S = input()

if n%2 == 0:
    p = n//2
    if S[:p] == S[p:]:
        print("Yes")
    else:
        print("No")
else:
    print("No")
    

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input()) 
s = input() 
b = int(N/2)

if N % 2 == 1:
  print('No')
else:
  s1 = s[0:b]
  s2 = s[b:N]
  print(s1)
  print(s2)
  if s1 == s2:
    print('Yes')
  else:
    print('No')



N = int(input()) 
s = input() 
b = int(N/2)
#print(int(b))
if N % 2 == 1:
  print('no')
else:
  s1 = s[0:b]
  s2 = s[b:N]
#  print(s1)
#  print(s2)
  if s1 == s2:
    print('yes')
  else:
    print('no')

N = int(input()) 
s = input() 
b = int(N/2)


if N % 2 == 0:
  s1 = s[0:b]
  s2 = s[b:N]

  if s1 == s2:
    print('Yes')
  else:
    print('No')
else:
  print('No')

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input())
S = input()
if N // 2 != 0:
    print('No')
else:
    letter = S[1:1+N//2]
    if S == letter + letter:
        print('Yes')
    else:
        print('No')
        

N = int(input())
S = input()
letter = S[0:N//2]
if S == letter*2:
    print('Yes')
else:
    print('No')
        

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
s = input()
if len(s) % 2 == 1:
  print("No")
  exit(0)
if s[:len(s) // 2 - 1] == s[len(s) // 2:]:
  print("Yes")
else:
  print("No")

s = input()
if s % 2 == 1:
  print("No")
  exit(0)
if s[:len(s) // 2 - 1] == s[len(s) // 2:]:
  print("Yes")
else:
  print("No")

_ = input()
s = input()
if len(s) % 2 == 1:
  print("No")
  exit(0)
if s[:len(s) // 2 - 1] == s[len(s) // 2:]:
  print("Yes")
else:
  print("No")

_ = input()
s = input()
if len(s) % 2 == 1:
  print("No")
  exit(0)
if s[:len(s) // 2] == s[len(s) // 2:]:
  print("Yes")
else:
  print("No")

Verdicts: Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
import sys
N = int(input()) 
n = int(N/2)
S = list(input())
T = [0]*n
for i in range(n):
    T[i] = S[i]
    if S[i] == T[i]*2:
        print("Yes")
        sys.exit()
    else:
        print("No")
        sys.exit()

N = int(input())
n = int(N/2) 
S = input()
if S[:n] == S[n:]:
    print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
def main():
    _len = int(input())
    _str = input()

    if _len % 2: 
        print("No")
        return

    print(_len/2)
    a, b = _str[:_len/2], _str[_len/2:]

    print("Yes" if a == b else "No")


if __name__ == '__main__':
    main()

def main():
    _len = int(input())
    _str = input()

    if _len > 0 or _len < 100 or _len % 2 : 
        print("No")
        return

    print(_len/2)
    a, b = _str[:_len/2], _str[_len/2:]

    print("Yes" if a == b else "No")


if __name__ == '__main__':
    main()


def main():
    _len = int(input())
    _str = input()

    if _len < 0 or _len > 100 or _len % 2 : 
        print("No")
        return
    idx = int(_len/2)
    a, b = _str[:idx], _str[idx:]

    print("Yes" if a == b else "No")


if __name__ == '__main__':
    main()

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
length=int(input())
c=input()

if length==1:
    print("no")
else:
    a=''
    b=''

    for i in range(length//2):
        a+=c[i]
        b+=c[length//2 + i]
   
    if a==b:
        print("yes")
    else:
        print("no")


length=int(input())
c=input()

if length%2!=0:
    print("no")

 
a=''
b=''

for i in range(length//2):
    a+=c[i]
    b+=c[length//2 + i]

if a==b:
    print("yes")
else:
    print("no")
    

length=int(input())
c=input()

if length==1:
    print("No")
elif length%2!=0:
    print("No")
else:
    a=''
    b=''

    for i in range(length//2):
        a+=c[i]
        b+=c[length//2 + i]

    if a==b:
        print("Yes")
    else:
        print("No")

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

Submission attempts (in order):
N = int(input())
S = input()
if N == 1:
    print("No")
    exit()

for i in range(1,N):
    s1 = S[:i]
    s2 = S[i:]
    print(s1,s2)
    if s1 == s2 and len(s1)*2 == N:
        print("Yes")
        exit()
print("No")

N = int(input())
S = input()
if N == 1:
    print("No")
    exit()

for i in range(1,N):
    s1 = S[:i]
    s2 = S[i:]
    if s1 == s2 and len(s1)*2 == N:
        print("Yes")
        exit()
print("No")

Verdicts: Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

print('Yes' if S[N//2:] == S[:N//2] else 'No')

N = int(input())
S = input()

print('Yes' if S[N//2:] == S[:N//2] else 'No')


Verdicts: Runtime Error

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if(s[:n/2-1] == s[n/2:]):
  print("Yes")
else:
  print("No")


n = int(input())
s = input()
 
if(s[:(int)(n/2-1)] == s[(int)(n/2):]):
  print("Yes")
else:
  print("No")


n = int(input())
s = input()

if n % 2 == 1:
  print("No")
elif s[:(int)(n/2-1)] == s[(int)(n/2):]:
  print("Yes")
else:
  print("No")


n = int(input())
s = input()

if n % 2 == 1:
  print("No")
elif s[:(int)(n/2)] == s[(int)(n/2):]:
  print("Yes")
else:
  print("No")

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Accepted
Problem: Given are a positive integer N and a string S of length N consisting of lowercase English letters.  Determine whether the string is a concatenation of two copies of some string. That is, determine whether there is a string T such that S = T + T.

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

if(S.len()%2 == 0):
  n = (S.len())/2
  if(S[0:(n/2-1)] == S[n/2:n]):
    print("Yes")
  else:
    print("No")
else:
  print("No")

N = int(input())
S = input()

if(N%2 == 0):
  n = N/2
  if(S[0:(n/2-1)] == S[n/2:N]):
    print("Yes")
  else:
    print("No")
else:
  print("No")

N = int(input())
S = input()

if(N%2 == 0):
  
  n = N//2
  
  if(S[:n] == S[n:]):
    print("Yes")
  else:
    print("No")
else:
  print("No")

Verdicts: Runtime Error

Runtime Error

Accepted