TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s=input()
n=len(s)
s1=s[:(n-1)//2]
s2=s[(n+3)//2-1:]
print(s1,s2)
if s==s[::1] and s1==s1[::-1] and s2==s2[::-1]:
    print('Yes')
else:
    print('No')

s=input()
n=len(s)
s1=s[:(n-1)//2]
s2=s[(n+3)-1//2:]
print(s1,s2)
if s==s[::1] and s1==s1[::-1] and s2==s2[::-1]:
    print('Yes')
else:
    print('No')

s=input()
n=len(s)
s1=s[:(n-1)//2]
s2=s[(n-1)//2+1:]

if s==s[::-1] and s1==s1[::-1] and s2==s2[::-1]:
    print('Yes')
else:
    print('No')

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
a = input()
def p(s,n):
    for i in range(n//2):
        if s[i] != s[-(i+1)]:
            return 0
    return 1
r = len(a)
print(a[(r+3)//2-1:],r-(r+3)//2+1)
if p(a,r) == 1 and p(a[:((r-1)//2)],(r-1)//2) == 1 and p(a[(r+3)//2-1:],r-(r+3)//2+1)== 1:
    print("Yes")
else:
    print("No")
    


a = input()
def p(s,n):
    for i in range(n//2):
        if s[i] != s[-(i+1)]:
            return 0
    return 1
r = len(a)
if p(a,r) == 1 and p(a[:((r-1)//2)],(r-1)//2) == 1 and p(a[(r+3)//2-1:],r-(r+3)//2+1)== 1:
    print("Yes")
else:
    print("No")
    


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):

def ispalindrome(s):
    h = len(s)
    if (h % 2) == 0:
        h = int(h/2)
        for a, b in zip(s[:h], reversed(s[h:])):
            if a != b: return 0
    else:
        h = int(h/2)
        for a, b in zip(s[:h], reversed(s[h+1:])):
            if a != b: return 0
    return 1

str_in = input()
N = len(str_in)
result = ispalindrome(str_in)

if result == 0:
    print('No')
else:
    str_half = str_in[:int((N-1)/2)]
    result &= ispalindrome(str_half)

    if result == 0:
      print('No')
    else:
        str_half = str_in[int((N+3)/2):]
        result &= ispalindrome(str_half)

        if result == 0:
            print('No')
        else:
            print('Yes')



def ispalindrome(s):
    h = len(s)
    if (h % 2) == 0:
        h = int(h/2)
        for a, b in zip(s[:h], reversed(s[h:])):
            if a != b: return 0
    else:
        h = int(h/2)
        for a, b in zip(s[:h], reversed(s[h+1:])):
            if a != b: return 0
    return 1

str_in = input()
N = len(str_in)
result = ispalindrome(str_in)

if result == 0:
    print('No')
else:
    if N == 3:
        print('Yes')
    else:
        str_half = str_in[:int((N-1)/2)]
        result &= ispalindrome(str_half)

        if result == 0:
            print('No')
        else:
            str_half = str_in[int(((N+3)/2)-1):]
            result &= ispalindrome(str_half)

            if result == 0:
                print('No')
            else:
                print('Yes')


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
def palindrome(s):
    return s == reversed(s)

S = input()
N = len(S)

print("Yes" if palindrome(S[:(N-1)//2]) and palindrome(S[(N+3)//2 - 1:]) else "No")

def palindrome(s):
    return s == "".join(list(reversed(s)))

S = input()
N = len(S)

s1 = S[:(N-1)//2]
s2 = S[(N+3)//2 -1:]
print("Yes" if palindrome(s1) and palindrome(s2) and palindrome(S) else "No")

Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

ans = 'Yes'

if s != s[::-1]:
  ans = 'No'
  
if s[:(len(s) - 1)//2] != s[(len(s) - 1)//2:]:
  ans = 'No'
  
if s[:(len(s) + 3)//2] != s[(len(s) + 1)//2:]:
  ans = 'No'
  
  
print(ans)

s = input()

ans = 'Yes'

if s != s[::-1]:
  ans = 'No'
  
if s[:(len(s) - 1)//2] != s[(len(s) - 1)//2::-1]:
  ans = 'No'
  
if s[:(len(s) + 3)//2] != s[(len(s) + 3)//2::-1]:
  ans = 'No'
  
  
print(ans)


s = input()

ans = 'Yes'

if s != s[::-1]:
  ans = 'No'
  
if s[:(len(s) - 1)//2] != s[(len(s) - 1)//2:]:
  ans = 'No'
  
if s[:(len(s) + 3)//2] != s[(len(s) + 3)//2:]:
  ans = 'No'
  
  
print(ans)


s = input()

ans = 'Yes'
if s != s[::-1]:
  ans ='No'

tmp = s[:(len(s)- 1) // 2]
if tmp != tmp[::-1]:
  ans = 'No'

tmp = s[(len(s)+3) //2 - 1:]
if tmp != tmp[::-1]:
  ans = 'No'

print(ans)

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

#initialize
IsKaibun = 'NO'

N = len(S)

def check_kaibun( mojiretu ):
    names = len(mojiretu)
    IsKaibunLocal = 'YES'
    for name in range((names + 1) // 2):
        if mojiretu[name] != mojiretu[names - 1 - name]:
            IsKaibunLocal = 'NO'

    return IsKaibunLocal


if N%2 != 1 and N < 3 and N >  99 :
    PRE_CHECK = 1


IsKaibun = check_kaibun(S)

#2nd check
if IsKaibun == 'YES':
    IsKaibun =  check_kaibun(S[ 0 : int((N-1)/2) ])


if IsKaibun == 'YES':
    IsKaibun = check_kaibun(S[ int((N+3)/2 - 1) : N ])

#output
print(IsKaibun)


S = input()

#initialize
IsKaibun = 0

N = len(S)

def check_kaibun( mojiretu ):
    names = len(mojiretu)
    for name in range((names + 1) // 2):
        if mojiretu[name] != mojiretu[names - 1 - name]:
            IsKaibun = 0
            break
    IsKaibun = 1
    return IsKaibun


if N%2 != 1 and N < 3 and N >  99 :
    PRE_CHECK = 1


check_kaibun(S)
#print(IsKaibun)

#2nd check
#print(S[ 0 : int((N-1)/2) ])
check_kaibun(S[ 0 : int((N-1)/2) ])
#print(IsKaibun)


check_kaibun(S[ int((N+3)/2) : N ])

#output
print(IsKaibun)


S = input()

#initialize
IsKaibun = 'No'

N = len(S)

def check_kaibun( mojiretu ):
    names = len(mojiretu)
    IsKaibunLocal = 'Yes'
    for name in range((names + 1) // 2):
        if mojiretu[name] != mojiretu[names - 1 - name]:
            IsKaibunLocal = 'No'

    return IsKaibunLocal


if N%2 != 1 and N < 3 and N >  99 :
    PRE_CHECK = 1


IsKaibun = check_kaibun(S)

#2nd check
if IsKaibun == 'Yes':
    IsKaibun =  check_kaibun(S[ 0 : int((N-1)/2) ])


if IsKaibun == 'Yes':
    IsKaibun = check_kaibun(S[ int((N+3)/2 - 1) : N ])

#output
print(IsKaibun)


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s = input()
n = len(s)
s1 = s[:(n - 1) // 2]
s2 = s[(n + 2) // 2:]
print(s == s[::-1] and s1 == s1[::-1] and s2 == s2[::-1])


s = input()
n = len(s)
s1 = s[:(n - 1) // 2]
s2 = s[(n + 2) // 2:]
print("Yes" if s == s[::-1] and s1 == s1[::-1] and s2 == s2[::-1] else "No")


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
a = input()
b = ""
i = len(a)
while i>0:
  i -= 1
  b += a[i]
if a == b:
  i = int((len(a)-1)/2)
  if a[0:i-1] == b[0:i-1]:
    print("yes")

a = input()
b = ""
i = len(a)
code = "No"
if a == a[::-1]:
  i = int((len(a)-1)/2)
  b = a[0:i]
  if b == b[::-1]:
    i = int((len(a)+3)/2)
    b = a[i-1:]
    if b == b[::-1]:
      code = 'Yes'
print(code)

Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

def evaluate(string):
  return string[:] == string[::-1]

print(S[:int((N-1)/2)])
print("Yes" if evaluate(S[:int((N-1)/2)]) else "No")

S = input()
N = len(S)

def evaluate(string):
  return string[:] == string[::-1]

print(S[:int((N-1)/2)])
print("Yes" if evaluate(S[:int((N-1)/2)]) and evaluate(S) else "No")

S = input()
N = len(S)

def evaluate(string):
  return string[:] == string[::-1]

print("Yes" if evaluate(S[:int((N-1)/2)]) and evaluate(S) else "No")

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
def g(S):
    N=len(S)
    if palindrome(S)==True and palindrome(S[((N+3)//2)-1])==True and palindrome(S[(N-1)//2])==True:
        return "Yes"
    else:
        return "No"
S=input()
print(g(S))

def palindrome(S):
    N=len(S)
    for i in range(N):
        if S[i]!=S[N-i-1]:
            return False
    return True
def g(S):
    N=len(S)
    if palindrome(S)==True and palindrome(S[(((N+3)//2)-1):])==True and palindrome(S[:((N-1)//2)])==True:
        return "Yes"
    else:
        return "No"
S=input()
print(g(S))
    

Verdicts: Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s = input()
l = len(s)
s1 = s[:int((l-1)/2)]
s2 = s1[::-1]
s3 = s[int((l+1)/2):]
s4 = s3[::-1]

m = s[:int((l-1)/2)]
n = len(m)
m1 = m[:int((n-1)/2)]
m2 = m1[::-1]
m3 = m[int((n+1)/2):]
m4 = m3[::-1]

a = s[int((l+3)/2-1):]
b = len(a)
a1 = a[:int((b-1)/2)]
a2 = a1[::-1]
a3 = a[int((b+1)/2):]
a4 = a3[::-1]

print(s, s1, s2, s3, s4)
print(m, m1, m2, m3, m4)
print(a, a1, a2, a3, a4)

if (s2 in s4) & (m2 in m4) & (a2 in a4):
    print("Yes")
else:
    print("No")

s = input()
l = len(s)
s1 = s[:int((l-1)/2)]
s3 = s[int((l+1)/2):]
s4 = s3[::-1]

m = s[:int((l-1)/2)]
n = len(m)
m1 = m[:int((n)/2)]
m3 = m[int((n+1)/2):]
m4 = m3[::-1]

a = s[int((l+3)/2-1):]
b = len(a)
a1 = a[:int((b-1)/2)]
a3 = a[int((b+1)/2):]
a4 = a3[::-1]


if (s1 in s4) & (m1 in m4) & (a1 in a4):
    print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

def check(s):
  if(s==s[::-1]):
    return True
  else:
    return False
  
n = len(s)
if(check(s[:(n-1)//2])):
  if(check(s[((n+3)//2)-1:])):
    if(check(2)):
    	print('Yes')
    else:
      print('No')
  else:
    print('No')
else:
     print('No')

s = input()

def check(s):
  if(s==s[::-1]):
    return True
  else:
    return False
  
n = len(s)
if(check(s[:(n-1)//2])):
  if(check(s[((n+3)//2)-1:])):
    if(check(2)):
      print('Yes')
    else:
      print('No')
  else:
    print('No')
else:
     print('No')

s = input()

def check(s):
  if(s==s[::-1]):
    return True
  else:
    return False
  
n = len(s)
if(check(s[:(n-1)//2])):
  if(check(s[((n+3)//2)-1:])):
    if(check(s)):
    	print('Yes')
    else:
      print('No')
  else:
    print('No')
else:
     print('No')

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

def judge(x):
  if "".join(list(reversed(x))) == x:
    return True
  else:
    return False
  
def solve(x):
  if judge(x) and judge(x[0:(len(x)-1)/2]) and judge(x[(len(x)+1)/2:]):
    print("Yes")
  else:
    print("No")
    
    
solve(S)

S = input()

def judge(x):
  if reversed(x) == x and x[0] == x[2] and x[-3] == x[-1]:
    return "Yes"
  else:
    return "No"
  
print(judge(S))

S = input()

def judge(x):
  if "".join(list(reversed(x))) == x:
    return True
  else:
    return False
  
def solve(x):
  if judge(x) and judge(x[0:int((len(x)-1)/2)]) and judge(x[int((len(x)+1)/2):]):
    print("Yes")
  else:
    print("No")
    
    
solve(S)

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s = input()
flg = 0
n = len(s)
s1 = s[0:(n-1)//2]
s2 = s[(n+3)//2-1:]
print(s1,s2,len(s1)//2-1)
for i in range(1,len(s1)//2-1):
  print(s1[i-1], s1[-i], s2[i-1], s2[-i])
  if s1[i-1] != s1[-i]:
    flg = 1
    break
  if s2[i-1] != s2[-i]:
    flg = 1
    break 

print("Yes" if flg == 0 else "No")


s = input()
flg = 0
n = len(s)
s1 = s[0:(n-1)//2]
s2 = s[(n+3)//2-1:]
t1 = s1[::-1]
t2 = s2[::-1]
#print(s1,s2,t1,t2)

for i in range(len(s1)):
  if s1[i] != t1[i] or s2[i] != t2[i]:
    flg = 1
    break
for i in range(n//2):
  if s[i] != s[-(i+1)]:
    flg = 1
    break
 
print("Yes" if flg == 0 else "No")


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
a = input()
if a == a[::-1]:
    b = a[:int((len(a) - 1) / 2)]
    c = a[int((len(a) + 3) / 2):]
    if b == b[::-1] and c == c[::-1]:
        print('Yes')
        exit(0)
print('No')


a = input()
if a == a[::-1]:
    b = a[:int((len(a) - 1) / 2)]
    c = a[int((len(a) + 3) / 2) - 1:]
    if b == b[::-1] and c == c[::-1]:
        print('Yes')
        exit(0)
print('No')


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

mae = S[:(N-1)/2]
ushiro = S[(N+3)/2:]


for i in range(N):
    if S[i] == S[-(i+1)]:
        for j in range(len(mae)):
            if mae[j] != mae[-(j + 1)] or ushiro[j] != ushiro[-(j + 1)]:
                print("No")
                break


            else:
                print("Yes")
                break
        break




    else:
        print("No")
        break










s = input()


if s != s[::-1]:
    print("No")
    exit()

mae = s[:len(s)//2]
ushiro = s[(len(s)+1)//2:]


if mae != mae[::-1]:
    print("No")
    exit()


if ushiro != ushiro[::-1]:
    print("No")
    exit()

print("Yes")

Verdicts: Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
l=int(input())
print((l/3)**3)

S=input()
N=len(S)
A=S[:(N-1)//2]
B=S[(N+3)//2-1:]
if S!=S[::-1] or A!=A[::-1] or B!=B[::-1]:
    print("No")
else:
    print("Yes")

Verdicts: Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

N_2 = (N+1) // 2 -1

if (N+1) % 4 == 0:
  N1 = N2 = (N+1) // 4 -1
  N3 = N4 = (N1+1) * 3 -1
else:
  N1 = (N-1) // 4 -1 
  N2 = N1 + 1
  N3 = N_2 + N1 +1
  N4 = N3 + 1
  
#print(N1, N2, N3, N4)
#print(S[0:N1+1], S[N2:N_2], S[N_2+1:N3+1], S[N4:N])

if S[0:N_2] == S[N_2:N][::-1] and S[0:N1+1] == S[N2:N_2][::-1] and S[N_2+1:N3+1] == S[N4:N][::-1]:
  print('Yes')
else:
  print('No')

S = input()
N = len(S)

N_2 = (N+1) // 2 -1

if (N+1) % 4 == 0:
  N1 = N2 = (N+1) // 4 -1
  N3 = N4 = (N1+1) * 3 -1
else:
  N1 = (N-1) // 4 -1 
  N2 = N1 + 1
  N3 = N_2 + N1 +1
  N4 = N3 + 1
  
#print(N1, N2, N3, N4)
#print(S[0:N1+1], S[N2:N_2], S[N_2+1:N3+1], S[N4:N], S[0:N_2], S[N_2+1:N])

if S[0:N_2] == S[N_2+1:N][::-1] and S[0:N1+1] == S[N2:N_2][::-1] and S[N_2+1:N3+1] == S[N4:N][::-1]:
  print('Yes')
else:
  print('No')

Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
n = input()
x = len(n)

if n == n[::-1]:
  if n[:((x-1)//2)] == n[:((x-1)//2)][::-1]:
    if n[:((x+3)//2)] == n[:((x+3)//2)][::-1]:
      print('Yes')
else:
  print('No')

n = input()
x = len(n)

if n == n[::-1]:
    if n[:((x-1)//2)] == n[:((x-1)//2)][::-1]:
        if n[((x+3)//2)-1:] == n[((x+3)//2)-1:][::-1]:
            print('Yes')
        else:
            print('No')
    else:
        print('No')
else:
    print('No')

Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s=input()
c=list(reversed(s))
n=len(s)
t=list(s[:int((n-1)/2)])
a=list(reversed(t))
u=list(s[int((n+3)/2)-1:])
b=list(reversed(u))
#print(b)
if t==a and u==b and s==c:
    print("Yes")   
else:
    print("No")
    

s=list(input())
c=list(reversed(s))
n=len(s)
t=list(s[:int((n-1)/2)])
a=list(reversed(t))
u=list(s[int((n+3)/2)-1:])
b=list(reversed(u))
#print(b)
if t==a and u==b and s==c:
    print("Yes")   
else:
    print("No")
    

Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
S = input().rstrip()
N = len(S)
for i in range((N - 1) // 2):
    if S[i] != S[N-1-i]:
        print("No")
        exit(0)
s = S[:(N-1) // 2]
n = len(s)
if n == 2 and s[0] != s[1]:
    print("No")
    exit(0)

for i in range((n - 1) // 2):
    print(s[i])
    print(s[n-1-i])
    if s[i] != s[n-1-i]:
        print("No")
        exit(0)
print("Yes")


S = input().rstrip()
N = len(S)
for i in range((N - 1) // 2):
    if S[i] != S[N-1-i]:
        print("No")
        exit(0)
s = S[:(N-1) // 2]
n = len(s)
if n == 2 and s[0] != s[1]:
    print("No")
    exit(0)

for i in range((n - 1) // 2):
    if s[i] != s[n-1-i]:
        print("No")
        exit(0)
print("Yes")


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
S=input()
N=len(S)
i=0

if((N-1)/2%2==1):
    while (i<((N-1)/2-1)/2):
        print(S[i],S[int((N-1)/2-i-1)],S[int((N-1)/2+1+i)],S[int(N-1-i)])
        if( (S[i]==S[int((N-1)/2-i-1)]) & (S[i]==S[int((N-1)/2+1+i)]) & (S[i]==S[int(N-1-i)]) ):
            i+=1
        else:
            break;
    if(i==int((N-1)/2-1)/2):
        print('Yes')
    else:
        print('No')
    
else:
    while (i<=(N-1)/4):
        print(S[i],S[int((N-1)/2-i-1)],S[int((N-1)/2+1+i)],S[int(N-1-i)])
        if( (S[i]==S[int((N-1)/2-i-1)]) & (S[i]==S[int((N-1)/2+1+i)]) & (S[i]==[int(N-1-i)]) ):
            i+=1
        else:
            break;
    if(i==(N-1)/4):
        print('Yes')
    else:
        print('No')

S=input()
N=len(S)
i=0
if((N-1)/2%2==1):
    while (i<((N-1)/2-1)/2):
        if( (S[i]==S[int((N-1)/2-i-1)]) & (S[i]==S[int((N-1)/2+1+i)]) & (S[i]==S[int(N-1-i)]) ):
            i+=1
        else:
            break;
    if(i==int((N-1)/2-1/2)):
        print('Yes')
    else:
        print('No')
    
else:
    while (i<(N-1)/4):
        if( (S[i]==S[int((N-1)/2-i-1)]) & (S[i]==S[int((N-1)/2+1+i)]) & (S[i]==S[int(N-1-i)]) ):
            i+=1
        else:
            break;
    if(i==int((N-1)/4)):
        print('Yes')
    else:
        print('No')


S=input()
N=len(S)
i=0
if((N-1)/2%2==1):
    while (i<=((N-1)/2-1)/2):
        if( (S[i]==S[int((N-1)/2-i-1)]) & (S[i]==S[int((N-1)/2+1+i)]) & (S[i]==S[int(N-1-i)]) ):
            i+=1
        else:
            break;
    if(i==int(((N-1)/2-1)/2+1)):
        print('Yes')
    else:
        print('No')
    
else:
    while (i<=(N-1)/4):
        if( (S[i]==S[int((N-1)/2-i-1)]) & (S[i]==S[int((N-1)/2+1+i)]) & (S[i]==S[int(N-1-i)]) ):
            i+=1
        else:
            break;
    if(i==int((N-1)/4+1)):
        print('Yes')
    else:
        print('No')

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s = input()
ll = len(s)
l = ll // 2

ans = True
t = l
if len(s) % 2 != 0:
    t = l - 1

for i in range(0, t):
    if s[i] != s[t-i]:
        ans = False

t = l
if len(s) % 2 != 0:
    t = l + 1

ll -= 1
c = 0
for i in range(t, ll):
    if s[i] != s[ll-c]:
        ans = False
    c += 1

if s[:t-1] != s[t:]:
    ans = False

print(ans)



s = input()
ll = len(s)
l = ll // 2

ans = True
t = l
if len(s) % 2 != 0:
    t = l - 1

for i in range(0, t):
    if s[i] != s[t-i]:
        ans = False

t = l
if len(s) % 2 != 0:
    t = l + 1

ll -= 1
c = 0
for i in range(t, ll):
    if s[i] != s[ll-c]:
        ans = False
    c += 1

if s[:t-1] != s[t:]:
    ans = False

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



Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
S = list(input())
N = len(S)
if S == S[::-1] :
    if S[:int((N-1)/2):] == S[:int((N-1)/2):-1] and S[int(((N+3)/2)-1):int(N):] ==  S[int(((N+3)/2)-1):int(N):-1] :
        print("Yes")
    else :
          print("No")


S = list(input())
N = len(S)
s1 = S[:int((N-1)/2):]
s2 = S[int(((N+3)/2)-1):int(N):]
if S == S[::-1] :
    if s1 == s1[::-1] and s2 == s2[::-1] :
        print("Yes")
    else:
        print("No")
else:
    print("No")


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

s = input()

def kaibun(s):
  for i in range(len(s)-(len(s)%2)):
  	if s[i] != s[-1*i-1]:
      return False
  return True

if kaibun(s):
  s_half = s[:(len(s)-1)//2]
  if kaibun(s_half):
    ans = 'Yes'
  else:
    ans = 'No'
else:
  ans = 'No'


print(ans)

def kaibun(s):
    for i in range(len(s)-(len(s)%2)):
        if s[i] != s[-1*i-1]:
            return False
    return True

if kaibun(s):
    s_half = s[:(len(s)-1)//2]
    if kaibun(s_half):
        ans = 'Yes'
    else:
        ans = 'No'
else:
    ans = 'No'

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

s = input()

def kaibun(s):
  for i in range(len(s)-(len(s)%2)):
    if s[i] != s[-1*i-1]:
      return False
  return True

if len(s) < 3:
  ans = 'No'
else:
  if kaibun(s):
    s_half = s[:(len(s)-1)//2]
    if kaibun(s_half):
      ans = 'Yes'
    else:
      ans = 'No'
  else:
    ans = 'No'
    
print(ans)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

if L > 5:
    small = round((N-1)/2)
    big = round((N+3)/2)-1
    smallS = S[0:small]
    bigS = S[big:N]

    if smallS == bigS:
        print('Yes')
    else:
        print('No')

S = str(input())
N = len(S)

small = round((N-1)/2)
big = round((N+3)/2)-1
smallS = S[0:small]
bigS = S[big:N]

if L > 5:
    if smallS == bigS:
        print('Yes')
    else:
        print('No')
else:
    print('No')

s = input()
n = len(s)

front = s[:(n-1)//2]
rear = s[(n+1)//2:]

if s == s[::-1] and front == front[::-1] ans rear == rear[::-1]:
  print('Yes')
else:
  print('No')

if L > 5:
    small = round((N-1)/2)
    big = round((N+3)/2)-1
    smallS = S[0:small]
    bigS = S[big:N]

    if smallS == bigS:
        print('Yes')
    else:
        print('No')
else:
    print('No')

s = input()
n = len(s)

front = s[:(n-1)//2]
rear = s[(n+1)//2:]

if s == s[::-1] and front == front[::-1] and rear == rear[::-1]:
  print('Yes')
else:
  print('No')

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s=input()
n=len(s)
count=0
a=(n-1)//2
b=(n+3)//2
for i in range(n//2):
  if s[i]!=s[-abs(i+1)]:
    count+=1
    
for i in range(a//2):
  c=ord(s[i])
  d=ord(s[(a-1-i)])
  if c!=d:
    count+=1

for i in range((n-b+1)//2):
  c=ord(s[n-i])
  d=ord(s[b-1+i])
  if c!=d:
    count+=1

if count!=0:
  print('No')
else:
  print('Yes')

s=input()
n=len(s)
count=0
a=(n-1)//2
b=(n+3)//2
for i in range(n//2):
  if s[i]!=s[-abs(i+1)]:
    count+=1
    
for i in range(a//2):
  if s[i]!=s[(a-1-i)]:
    count+=1

for i in range((n-b+1)//2):
  if s[-(i+1)]!=s[b-1+i]:
    count+=1

if count!=0:
  print('No')
else:
  print('Yes')


Verdicts: Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
#input
S = input()

#output
N = len(S)
k = N//2
l = (N-3)//4
m = (3*N-1)//4
if N == 3:
    if S[0] == S[3]:
        print("Yes"):
    else:
        print("No"):
else:
    if (S[0:k] == S[-1:k:-1] )and (S[0:l] == S[(N-3)//2:l:-1]) and (S[(N+1)//2:m] == S[N-1:m:-1]):
        print("Yes")
    else:
        print("No")

#input
S = input()

#output
N = len(S)

if (S == S[::-1]) and (S[:(N-1)//2] == S[:(N-1)//2][::-1]) and (S[(N+3)//2-1:] == S[(N+3)//2-1:][::-1]):
    print("Yes")
else:
    print("No")

Verdicts: Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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

a = S[0:(N - 1) // 2]
b = S[(N + 3) // 2 - 1:]

N2 = len(a)
c = a[::-1]
d = b[::-1]

print(a[0:(N2 + 1) // 2])
print(b[0:(N2 + 1) // 2])
print(c[0:(N2 + 1) // 2])
print(d[0:(N2 + 1) // 2])


if N2 % 2 == 0:
    if a[0:N2//2] == c[0:N2//2] and b[0:N2//2] == d[0:N2//2]:
        print('Yes')
    else:
        print('No')

if N2 % 2 == 1:
    if a[0:(N2+1)//2] == c[0:(N2+1)//2] and b[0:(N2+1)//2] == d[0:(N2+1)//2]:
        print('Yes')
    else:
        print('No')


S = input()
N = len(S)

a = S[0:(N - 1) // 2]
b = S[(N + 3) // 2 - 1:]

if S[::] != S[::-1]:
    print('No')
    exit()

N2 = len(a)
c = a[::-1]
d = b[::-1]
#print(a, b)

if N2 % 2 == 0:
    # print(a[0:N2 // 2])
    # print(c[0:N2 // 2])
    # print(b[0:N2 // 2])
    # print(d[0:N2 // 2])
    if a[0:N2//2] == c[0:N2//2] and b[0:N2//2] == d[0:N2//2]:
        print('Yes')
    else:
        print('No')

if N2 % 2 == 1:
    # print(a[0:(N2 + 1) // 2])
    # print(c[0:(N2 + 1) // 2])
    # print(b[0:(N2 + 1) // 2])
    # print(d[0:(N2 + 1) // 2])
    if a[0:(N2+1)//2] == c[0:(N2+1)//2] and b[0:(N2+1)//2] == d[0:(N2+1)//2]:
        print('Yes')
    else:
        print('No')


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
S = input()
N = len(S)
SF_num = int((N-1)/2)
SF = S[:SF_num]
SF_rev = SF[::-1]
SB = S[SF_num-1:]
SB_rev = SB[::-1]

if SF == SB_rev:
    if SF == SF_rev:
        if SB == SB_rev:
            print("Yes")
else:
    print("No")

S = input()
N = len(S)
SF_num = int((N-1)/2)
SF = S[:SF_num]
SF_rev = SF[::-1]
SB = S[:SF_num-1]
SB_rev = SB[::-1]

if SF == SB_rev:
    if SF == SF_rev:
        if SB == SB_rev:
            print("Yes")
else:
    print("No")

S = input()
N = len(S)
SF_num = int((N-1)/2)
SF = S[:SF_num]
SF_rev = SF[::-1]
SB_num = int((N+3)/2)
SB = S[SB_num-1:]
SB_rev = SB[::-1]

if SF == SB_rev and SF == SF_rev and SB == SB_rev:
    print("Yes")
else:
    print("No")

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
n = input()
m = len(n)
if n == n[::-1]:
  k = n[0:(m-1)//2]
  l = n[(m+3)//2-1:m]
  print(k,l)
  if k == k[::-1]:
    if l == l[::-1]:
      print('Yes')
      exit()
print('No')


n = input()
m = len(n)
if n == n[::-1]:
  k = n[0:(m-1)//2]
  l = n[(m+3)//2-1:m]
  if k == k[::-1]:
    if l == l[::-1]:
      print('Yes')
      exit()
print('No')


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s = input()
for i in [s, s[:len(s)//2], s[len(s)//2+1:]]:
  if i != i[::-1]:
    print("No")
  break
else:
  print("Yes")

s = input()
for i in [s, s[:len(s)], s[len(s)+1:]]:
  if i != i[::-1]:
    print("No")
  break
else:
  print("Yes")

s = input()
print("Yes" if s == sorted(s) and s[:len(s)] == sorted(s[:len(s)]) and s[len(s)+1:] == sorted(s[:len(s)+1]) else "No")


s = input()
for i in [s, s[:len(s)//2], s[len(s)//2+1:]]:
  if i != i[::-1]:
    print("No")
    break
else:
  print("Yes")

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

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


def is_palindrome(s):
    s_reverse = s[::-1]
    if s == s_reverse:
        return True
    else:
        return False

print(is_palindrome(S))

if is_palindrome(S) and is_palindrome(S[:(N-1)//2]) and is_palindrome(S[(N+3)//2-1:]):
    print('Yes')
else:
    print('No')


S = input()
N = len(S)


def is_palindrome(s):
    s_reverse = s[::-1]
    if s == s_reverse:
        return True
    else:
        return False

if is_palindrome(S) and is_palindrome(S[:(N-1)//2]) and is_palindrome(S[(N+3)//2-1:]):
    print('Yes')
else:
    print('No')


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
def main():
    S = input()
    len_s = len(S)
    flag = False
    if S == S[::-1]:
        if S[len_s // 2] == S[len_s // 2:-1:-1]:
            if S[len_s // 2:] == S[-1:len_s // 2:-1]:
                flag = True
    if flag:
        print('Yes')
    else:
        print('No')


if __name__ == '__main__':
    main()

def main():
    S = input()
    len_s = len(S)
    flag = False
    if S == S[::-1]:
        if S[0:len_s // 2] == S[len_s // 2 - 1::-1]:
            if S[len_s // 2 + 1:] == S[-1:len_s // 2:-1]:
                flag = True
    # print(S[0:len_s // 2], S[len_s // 2 - 1::-1])
    # print(S[len_s // 2 + 1:], S[-1:len_s // 2:-1])
    if flag:
        print('Yes')
    else:
        print('No')


if __name__ == '__main__':
    main()


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s = list(input())
n = len(s)
if n==n[::-1] and n[0:int((n-1)/2)]==n[0:int((n-1)/2)][::-1] and n[int((n+3)/2-1):n]==n[int((n+3)/2-1):n][::-1]:
  print('Yes')
else:
  print('No')


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


Verdicts: Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):

s = input()
len_s = len(s)
if s[:int((len_ s -1 ) /2)] != s[int((len_ s -1 ) / 2 +1):]:
    print('No')
else:
    tmp = s[:int((len_ s -1 ) /2)]
    if len(tmp) == 1:
        print('Yes')
    else:
        if len(tmp ) %2 == 1:
            if tmp[:int((len(tmp) - 1) / 2)] == tmp[int((len(tmp) - 1) / 2 + 1):][::-1]:
                print('Yes')
            else:
                print('No')
        else:
            if tmp[:int(len(tmp) / 2)] == tmp[int(len(tmp) / 2):][::-1]:
                print('Yes')
            else:
                print('No')


s = input()
len_s = len(s)
if s[:int((len_s-1)/2)] != s[int((len_s-1)/2+1):]:
    print('No')
else:
    tmp = s[:int((len_s-1)/2)]
    if len(tmp) == 1:
        print('Yes')
    else:
        if len(tmp)%2 == 1:
	        if tmp[:int((len(tmp) - 1) / 2)] == tmp[int((len(tmp) - 1) / 2 + 1):][::-1]:
            	print('Yes')
        	else:
            	print('No')
        else:
            if tmp[:int(len(tmp) / 2)] == tmp[int(len(tmp) / 2):][::-1]:
            	print('Yes')
        	else:
            	print('No')
          



s = input()
len_s = len(s)
if s[:int((len_s-1) /2)] != s[int((len_s-1) / 2 +1):]:
    print('No')
else:
    tmp = s[:int((len_s -1 ) /2)]
    if len(tmp) == 1:
        print('Yes')
    else:
        if len(tmp ) %2 == 1:
            if tmp[:int((len(tmp) - 1) / 2)] == tmp[int((len(tmp) - 1) / 2 + 1):][::-1]:
                print('Yes')
            else:
                print('No')
        else:
            if tmp[:int(len(tmp) / 2)] == tmp[int(len(tmp) / 2):][::-1]:
                print('Yes')
            else:
                print('No')


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
S = [i for i in input()]
f = 0
for i in range(len(S)//2):
  if not S[i] == S[-i]:
    f = 1
    print('No')
    break
if f == 0:
  for i in range(int((len(S)-1)/2)):
    if not S[i] == S[int((len(S)-1)/2-i)]:
      f = 1
      print('No')
      break
if f == 0:
  for i in range(int((len(S)+3)/2), len(S)) and f == 0:
    if not S[i] == S[-i]:
      f = 1
      print('No')
      break
if f ==0:
  print('Yes')

S = [i for i in input()]
f = 0
for i in range(len(S)//2):
  if not S[i] == S[-i]:
    f = 1
    print('No')
    break
if f == 0:
  s = S[:int((len(S)-1)/2)]
  for i in range(len(s)//2):
    if not s[i] == s[-i]:
      f = 1
      print('No')
      break
if f == 0:
  s = S[int((len(S)+3)/2):]
  for i in range(len(S)//2):
    if not s[i] == s[-i]:
      f = 1
      print('No')
      break
if f ==0:
  print('Yes')

S = [i for i in input()]
f = 0
for i in range(len(S)//2):
  if not S[i] == S[-i]:
    f = 1
    print('No')
    break
if f == 0:
  for i in range(int((len(S)-1)/2)):
    if not S[i] == S[int((len(S)-1)/2-i)]:
      f = 1
      print('No')
      break
if f == 0:
  for i in range((len(S)+3)/2, len(S)) and f == 0:
    if not S[i] == S[-i]:
      f = 1
      print('No')
      break
if f ==0:
  print('Yes')

S = [i for i in input()]
f = 0
for i in range(len(S)//2):
  if not S[i] == S[-i]:
    f = 1
    print('No')
    break
if f == 0:
  s = S[:int((len(S)-1)/2)]
  for i in range(len(s)):
    if not s[i] == s[-i]:
      f = 1
      print('No')
      break
if f == 0:
  s = S[int((len(S)+3)/2):]
  for i in range(len(S)):
    if not s[i] == s[-i]:
      f = 1
      print('No')
      break
if f ==0:
  print('Yes')

S = [i for i in input()]
f = 0
for i in range(len(S)//2):
  #print(S[i], S[-1-i])
  if not S[i] == S[-1-i]:
    f = 1
    print('No')
    break
#print(f)
if f == 0:
  s = S[:int((len(S)-1)/2)]
  for i in range(int(len(s)//2)):
    if not s[i] == s[-1-i]:
      f = 1
      print('No')
      break
#print(f)
if f == 0:
  s = S[int((len(S)+3)/2-1):]
  for i in range(int(len(s)//2)):
    #print(s[i], s[-1-i])
    if not s[i] == s[-1-i]:
      f = 1
      print('No')
      break
if f ==0:
  print('Yes')

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
import math
s = list(input())
n = int(len(s))
s1 = s[ : int((n-1)/2)]
s2 = s[int((n+3) / 2) - 1 : n]
print(s1)
print(s2)
flag = 0
print(int(len(s1)))
for i in range(int(len(s1) / 2)):
    if s1[i] == s1[int(len(s1)) - i - 1]:
        flag = 1
    else:
        break

for i in range(int(len(s2) / 2)):
    if s2[i] == s2[int(len(s2)) - i - 1]:
        flag = 1
    else:
        break

print('Yes' if flag == 1  else 'No')

import math
s = list(input())
n = len(s)
s1 = s[ : (n-1) // 2]
s2 = s[(n+3) // 2 - 1 : n]
flag = 1

for i in range(len(s) // 2):
    if s[i] != s[- i - 1]:
        flag = 0

for i in range(len(s1) // 2):
    if s1[i] != s1[- i - 1]:
        flag = 0

for i in range(len(s2) // 2):
    if s2[i] != s2[- i - 1]:
        flag = 0

print('Yes' if flag == 1  else 'No')


Verdicts: Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
s=input()
n = len(s)
front = s[:(n-1)//2]
back = s[(n+3)//2-1:n]
print(front,back)
if s==s[::-1]:
  if front==front[::-1]:
    if back==back[::-1]:
      print('Yes')
    else:
      print('No')
  


s=input()
n = len(s)
front = s[1:(n-1)//2]
back = s[(n+3)//2:n]
if s==s[::-1]:
  if front==front[::-1]:
    if back==back[::-1]:
      print('Yes')
    else:
      print('No')
  


s=input()
n = len(s)
front = s[:(n-1)//2]
back = s[(n+3)//2:n]
if s==s[::-1]:
  if front==front[::-1]:
    if back==back[::-1]:
      print('Yes')
    else:
      print('No')
  


s=input()
n = len(s)
front = s[:(n-1)//2]
back = s[(n+3)//2-1:n]
if s==s[::-1]:
  if front==front[::-1]:
    if back==back[::-1]:
      print('Yes')
    else:
      print('No')
  else:
      print('No')
else:
      print('No')
  

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: A string S of an odd length is said to be a _strong palindrome_ if and only if all of the following conditions are satisfied:    * S is a palindrome.   * Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.   * The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.  Determine whether S is a strong palindrome.

Submission attempts (in order):
def parindrome(s):
    print(s)
    if s[::] == s[::-1]:
        return True
    return False

def string_parindrome(s):
    if parindrome(s):
        N = len(s)
        if parindrome(s[:((N-1)//2):]) and parindrome(s[((N+3)//2)-1::]):
            return "Yes"
    return "No"
    

S = input()
print(string_parindrome(S))


def parindrome(s):
    if s[::] == s[::-1]:
        return True
    return False

def string_parindrome(s):
    if parindrome(s):
        N = len(s)
        if parindrome(s[:((N-1)//2):]) and parindrome(s[((N+3)//2)-1::]):
            return "Yes"
    return "No"
    

S = input()
print(string_parindrome(S))


Verdicts: Wrong Answer

Accepted