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):
def checkPalindrome(str1, str2):
  for i in range(len(str1) // 2):
    if str1[i] != str2[i]:
      return False
  return True
    
s = input()
rs = ''.join(list(reversed(s)))
print(s, rs)
cri1 = checkPalindrome(s, rs)

s2 = s[:len(s) // 2]
rs2 = ''.join(list(reversed(s2)))
print(s2, rs2)
cri2 = checkPalindrome(s2, rs2)

s3 = s[len(s) // 2 + 1:len(s)]
rs3 = ''.join(list(reversed(s3)))
print(s3, rs3)
cri3 = checkPalindrome(s3, rs3)

if cri1 and cri2 and cri3:
  print('Yes')
else:
  print('No')


def checkPalindrome(str1, str2):
  for i in range(len(str1) // 2):
    if str1[i] != str2[i]:
      return False
  return True
    
s = input()
rs = ''.join(list(reversed(s)))
cri1 = checkPalindrome(s, rs)

s2 = s[:len(s) // 2]
rs2 = ''.join(list(reversed(s2)))
cri2 = checkPalindrome(s2, rs2)

s3 = s[len(s) // 2 + 1:len(s)]
rs3 = ''.join(list(reversed(s3)))
cri3 = checkPalindrome(s3, rs3)

if cri1 and cri2 and cri3:
  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):
#!/usr/bin/env python3

import copy

s = list(str(input()))
N = len(s)


def disc(s):
    s1 = s[:len(s)//2]
    s2 = s[len(s)+1//2:]
    s2.reverse()
    if s1 == s2:
        return True
    else:
        return False


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


#!/usr/bin/env python3

import copy

s = list(str(input()))
N = len(s)


def disc(s):
    s1 = s[:len(s)//2]
    s2 = s[len(s)//2+1:]
    s2.reverse()

    if s1 == s2:
        return True
    else:
        return False


print(s)
print(s[:(N-1)//2])
print(s[(N+3)//2-1:])

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


#!/usr/bin/env python3

s = list(str(input()))
N = len(s)


def disc(s):
    s1 = s[:len(s)//2]
    s2 = s[len(s)//2:]
    s2.reverse()
    if s1 == s2:
        return True
    else:
        return False


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


#!/usr/bin/env python3

s = list(str(input()))
N = len(s)


def disc(s):
    s1 = s
    s2 = s[:]
    s2.reverse()
    if s1 == s2:
        return True
    else:
        return False


if disc(s) and disc(s[:(N-1)//2]) and disc(s[(N+3)//2-1:]):
    print("Yes")
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 main():
    S = list(input())
    N = len(S)

    kaibun_check(S)
    S1 = S[0:(N-1)//2 + 1]
    kaibun_check(S1)
    S2 = S[(N+3)//2 + 1: -1]
    kaibun_check(S2)

    print('Yes')


def kaibun_check(L):
    L_ = list(L.__reversed__())
    for s, s_ in zip(L, L_):
        if s != s_:
            print('No')
            exit()


if __name__ == '__main__':
    main()


def main():
    S = list(input())
    N = len(S)

    kaibun_check(S)

    S1 = S[0:(N-1)//2]
    kaibun_check(S1)

    S2 = S[(N+3)//2:-1]
    kaibun_check(S2)

    print('Yes')


def kaibun_check(L):
    L_ = list(L.__reversed__())
    for s, s_ in zip(L, L_):
        if s != s_:
            print('No')
            exit()


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 = input()

def is_kaibun(s):
    l = len(s)
    print('former', s[:int(l/2)])
    print('latter', s[:-(int(l/2))-1:-1])
    if s[:int(l/2)] == s[:-(int(l/2))-1:-1]:
        return True
    else:
        return False

if is_kaibun(S):
    if is_kaibun(S[:int((len(S)-1)/2)]):
        if is_kaibun(S[int((len(S)+3)/2)-1:]):
            print('Yes')
            exit()
print('No')


S = input()

def is_kaibun(s):
    l = len(s)
    # print('former', s[:int(l/2)])
    # print('latter', s[:-(int(l/2))-1:-1])
    if s[:int(l/2)] == s[:-(int(l/2))-1:-1]:
        return True
    else:
        return False

if is_kaibun(S):
    if is_kaibun(S[:int((len(S)-1)/2)]):
        if is_kaibun(S[int((len(S)+3)/2)-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 = str(input())
t = s[::-1]
if(s != t):
    print("No")
    exit
c = ""
for i in range((len(s)-1)//2):
    c += s[i]
e = c[::-1]
if(e != c):
    print("No")
    exit()
r = ""
for i in range(((len(s)+3)//2)-1,len(s),1):
    r += s[i]
y = r[::-1]
if(r != y):
    print("No")
    exit()
"""
print("Yes")
print(s,t)
print(e,c)
print(r,y)

s = str(input())
t = s[::-1]
if(s != t):
    print("No")
    exit()
c = ""
for i in range((len(s)-1)//2):
    c += s[i]
e = c[::-1]
if(e != c):
    print("No")
    exit()
r = ""
for i in range(((len(s)+3)//2)-1,len(s),1):
    r += s[i]
y = r[::-1]
if(r != y):
    print("No")
    exit()
print("Yes")
"""
print(s,t)
print(e,c)
print(r,y)
"""

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):
a=input()
#b=reversed(a)
c=a[0:int((len(a)-1)/2)]
b=''.join(list(reversed(a)))
#d=reversed(a[int((len(a)+3)/2)-1:])
d=''.join(list(reversed(a[int((len(a)+3)/2)-1:])))
print(a,b,c,d)

if a!=b:
  print("No")
elif c!=d:
  print("No")
else:
  print("Yes")

a=input()
#b=reversed(a)
c=a[0:int((len(a)-1)/2)]
b=''.join(list(reversed(a)))
d=a[int((len(a)+3)/2)-1:]

if a!=b:
  print("No")
elif c!=d:
  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):
a = input()
l = len(a)
m = a[:l//2]
n = a[l//2 + 1 :]
if a[::-1] == a and m == m[::-1] and n == n[::-1]:
    print("gh")

a = input()
l = len(a)
m = a[:l//2]
n = a[l//2 + 1 :]
if a[::-1] == a and m == m[::-1] and n == 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):
s = input()
n = len(s)
a = s[:(n-1)//2]
b = s[(n+3)//2:]

if a == b and a == a[::-1]:
  print('Yes')
else:
  print('No')

s = input()
n = len(s)
a = s[:(n-1)//2]
b = s[(n+3)//2:]

if a == b and a == a[::-1] and b == b[::-1]:
  print('Yes')
else:
  print('No')

s = input()
n = len(s)
a = s[:(n-1)//2]
b = s[(n+1)//2:]

if a == b and a == a[::-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()
n=len(s)
n1=((n-1)//2)
n2=(n+3)//2
s1=s[0:n1]
s2=s[n2-1:]
if s==s[::-1] and s1==s1[::-1] and s2==s2[::-1]:
    print('yes')
else:
    print('no')

s=input()
n=len(s)
n1=((n-1)//2)
n2=(n+3)//2
s1=s[0:n1]
s2=s[n2-1:]
if s==s[::-1] and s1==s1[::-1] and s2==s2[::-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):
S = input()
flg = False
for i in range(len(S)//2):
    if S[i] == S[len(S)-i]:
        flg = True
    else:
        flg = False
for i in range((len(S)-1) //2//2):
    if S[i] == S[(len(S)-1)//2-i]:
        pass
    else:
        flg = False
for i in range((len(S)-(len(S)+3)//2)//2):
    if S[i] == S[(len(S)+3)//2 -i]:
        pass
    else:
        flg = False

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

S = input()
flg = False
for i in range(len(S)):
    if S[i] == S[len(S)-i]:
        flg = True
    else:
        flg = False
for i in range((len(S)-1) /2):
    if S[i] == S[(len(s)-1)/2-i]:
        pass
    else:
        flg = False
for i in range((len(S)+3)/2, N):
    if S[i] == S[(len(S)+3)/2) -i]:
        pass
    else:
        flg = False

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

s = input()
r1 = s[::-1]
n = len(s)
r2 = s[0:(n-1)//2]
r2r = r2[::-1]
r3 = s[(n+3)//2-1:]
r3r = r3[::-1]
if s == r1 and r2 == r2r and r3 == r3r:
    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):
def palindrome(x):
    reverse = x[::-1]
    for i in range(len(x)):
        if (x[i] != reverse[i]):
            return False
    return True

c = input()
l = len(c)
["No","Yes"][palindrome(c) & palindrome(c[:(l-1)//2])& palindrome(c[(l+2)//2:])]

def palindrome(x):
    reverse = x[::-1]
    for i in range(len(x)):
        if (x[i] != reverse[i]):
            return False
    return True

c = input()
l = len(c)
print(["No","Yes"][palindrome(c) & palindrome(c[:(l-1)//2])& palindrome(c[(l+2)//2:])])

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()
L = list(S)
N = len(L)

revS = list(reversed(L))
print(revS)

preS = L[:int((N - 1) / 2)]
revPreS = list(reversed(preS))
print(revPreS)

backS = L[int((N + 2) / 2):]
revBackS = list(reversed(backS))
print(revBackS)

if L != revS:
    print("No")
elif preS != revPreS:
    print("No")
elif backS != revBackS:
    print("No")
else:
    print("Yes")


S = input()
L = list(S)
N = len(L)

revS = list(reversed(L))

preS = L[:int((N - 1) / 2)]
revPreS = list(reversed(preS))

backS = L[int((N + 3) / 2):]
revBackS = list(reversed(backS))

if L != revS:
    print("No")
elif preS != revPreS:
    print("No")
elif backS != revBackS:
    print("No")
else:
    print("Yes")


S = input()
L = list(S)
N = len(L)

revS = list(reversed(L))

preS = L[:int((N - 1) / 2)]
revPreS = list(reversed(preS))

backS = L[int((N + 2) / 2):]
revBackS = list(reversed(backS))

if L != revS:
    print("No")
elif preS != revPreS:
    print("No")
elif backS != revBackS:
    print("No")
else:
    print("Yes")


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):
inp = input()
part1 = inp[0:int((len(inp)-1)/2)]
part2 = inp[int((len(inp)+1)/2):]


def isParin(S):
    n = len(S)
    flg = 0
    for i in range(int(n/2)):
        print(S[i], S[n-1-i])
        if S[i] != S[n-1-i]:
            flg += 1
    if flg == 0:
        return True
    else:
        return False


if isParin(inp):
    if part1 == part2:
        print('Yes')
    else:
        print('No')
else:
    print('No')


inp = input()
part1 = inp[0:int((len(inp)-1)/2)]
part2 = inp[int((len(inp)+1)/2):]


def isParin(S):
    n = len(S)
    flg = 0
    for i in range(int(n/2)):
        print(S[i], S[n-1-i])
        if S[i] != S[n-1-i]:
            flg += 1
    if flg == 0:
        return True
    else:
        return False


if isParin(inp):
    if part1 == part2:
        print('Yes')
else:
    print('No')


inp = input()
part1 = inp[0:int((len(inp)-1)/2)]
part2 = inp[int((len(inp)+1)/2):]


def isParin(S):
    n = len(S)
    flg = 0
    for i in range(int(n/2)):
        print(S[i], S[n-1-i])
        if S[i] != S[n-1-i]:
            flg += 1
    if flg == 0:
        return True
    else:
        return False


if isParin(inp):
    if part1 == part2:
        print('Yes')
    else:
        print('No')


inp = input()
part1 = inp[0:int((len(inp)-1)/2)]
part2 = inp[int((len(inp)+1)/2):]


def isParin(S):
    n = len(S)
    flg = 0
    for i in range(int(n/2)):
        if S[i] != S[n-1-i]:
            flg += 1
    if flg == 0:
        return True
    else:
        return False


if isParin(inp):
    if part1 == part2:
        print('Yes')
    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):
# -*- coding: utf-8 -*-

'''
akasaka
'''

import sys

S = input()

for i in range(len(S)):
    if not S[i] == S[len(S)-1 - i]:
        print('No')
        sys.exit()

    if i < (len(S)-1)/2:
        if not S[i] == S[int((len(S)-1)/2) -1 - i]:
            print('No')
            sys.exit()

# print(list(S))
# print(len(S))
# print(int((len(S)+3)/2)-1)
newS = list(S)[int((len(S)+3)/2 -1):]
print(newS)

for i in range(len(newS)):
    if not S[i] == S[len(S) - 1 - i]:
        print('No')
        sys.exit()

print('Yes')






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

'''
akasaka

'''

import sys

S = input()

for i in range(len(S)):
    
    if not S[i] == S[len(S)-1 - i]:
        print('No')
        sys.exit()


newS = list(S)[:int((len(S)-1)/2)]
for i in range(len(newS)):
    if not newS[i] == newS[len(newS) - 1 - i]:
        print('No')
        sys.exit()

newS = list(S)[int((len(S)+3)/2 - 1):]
for i in range(len(newS)):
    if not newS[i] == newS[len(newS) - 1 - i]:
        print('No')
        sys.exit()

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):
str = input("")
n = len(str)
BOOL = True
for i in range(int((n+1)/2)):
    BOOL = BOOL and str[i] == str[n-1-i]

for i in range(int((n-1)/2)):
    BOOL = BOOL and str[i] == str[int((n-1)/2-1-i)]

for i in range(int((n-1)/2)):
    BOOL = BOOL and str[int((n+3)/2-1+i)] == str[n-1-i]

print(BOOL)

str = input("")
n = len(str)
BOOL = True
for i in range(int((n + 1) / 2)):
    BOOL = BOOL and str[i] == str[n - 1 - i]

for i in range(int((n - 1) / 2)):
    BOOL = BOOL and str[i] == str[int((n - 1) / 2 - 1 - i)]

for i in range(int((n - 1) / 2)):
    BOOL = BOOL and str[int((n + 3) / 2 - 1 + i)] == str[n - 1 - i]

if BOOL == True:
    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():
    import sys
    input = sys.stdin.buffer.readline
    s = input()
    n = len(s)
    s_l = s[:(n-1)/2]
    s_r = s[(n+3)/2:]
    if s == s[::-1] and s_l == s_l[::-1] and s_r == s_r[::-1]:
        print('Yes')
    else:
        print('No')


if __name__ == '__main__':
    main()

def main():
    import sys
    #input = sys.stdin.readline
    s = input()
    n = len(s)
    s_l = s[:int((n-1)/2)]
    s_r = s[int((n+1)/2):]
    print(s_l,s_r)
    if s == s[::-1] and s_l == s_l[::-1] and s_r == s_r[::-1]:
        print('Yes')
    else:
        print('No')


if __name__ == '__main__':
    main()

def main():
    import sys
    #input = sys.stdin.readline
    s = input()
    n = len(s)
    s_l = s[:int((n-1)/2)]
    s_r = s[int((n+1)/2):]
    if s == s[::-1] and s_l == s_l[::-1] and s_r == s_r[::-1]:
        print('Yes')
    else:
        print('No')


if __name__ == '__main__':
    main()

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):
def palind(word):
  word = word.lower()
  return word[::-1] ==word

num1 = int((N-1)/2)
num2 = int((N+3)/2)

text1 =S[0::num1]
text2 =S[num2-1::]

if palind(S) == True and palind(text1) == True and palind(text2) == True:
  print("Yes")
else:
  print("No")

S = input()
N = len(S)

def palind(word):
  word = word.lower()
  return word[::-1] ==word

num1 = int((N-1)/2)
num2 = int((N+3)/2)

text1 =S[0::num1]
text2 =S[num2-1::]

if palind(S) == True and palind(text1) == True and palind(text2) == True:
  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 == reversed(a)
s1 = s[:(n-1)//2]
b = s1 == reversed(s1)
s2 = s[(n+3)//2 + 1:]
c = s2 == reversed(s2)

print(['No', 'Yes'][a and b and c])

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

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

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):
a=input()
a=list(a)
a1=[]
b1=[]
c1=[]
for i in range(len(a)-1,-1,-1):
    a1.append(a[i])
b=a[0:(len(a)-1)//2]
for i in range(len(b)-1,-1,-1):
    b1.append(a[i])
c=a[(len(a)+3)//2-1:len(a)]
for i in range(len(c)-1,-1,-1):
    c1.append(a[i])



if(a==a1):
    if(b==b1 and c==c1):
        print("YES")
    else:
        print("NO")
else:
    print("NO")


a=input()
a=list(a)
a1=[]
b1=[]
c1=[]
for i in range(len(a)-1,-1,-1):
    a1.append(a[i])
b=a[0:(len(a)-1)//2]
for i in range(len(b)-1,-1,-1):
    b1.append(a[i])
c=a[(len(a)+3)//2-1:len(a)]
for i in range(len(c)-1,-1,-1):
    c1.append(a[i])



if(a==a1):
    if(b==b1 and c==c1):
        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):
def kalin(s):
  N=len(s)
  for i in range(N//2):
    if s[i]!=s[-1-i]:
      return False
  return True

def strong(s):
  N=len(s)
  tail = (N-1)//2
  s0=s[0:tail]
  head = (N+3)//2
  s1=s[head-1:]
  return kalin(s0) and kalin(s1) and kalin(s)  

S=input()

print(strong(S))



def kalin(s):
  N=len(s)
  for i in range(N//2):
    if s[i]!=s[-1-i]:
      return False
  return True

def strong(s):
  N=len(s)
  tail = (N-1)//2
  s0=s[0:tail]
  head = (N+3)//2
  s1=s[head-1:]
  # print('s0={} s1={}'.format(s0,s1))
  return kalin(s0) and kalin(s1) and kalin(s)  

if strong(input()):
  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 = list(input())
n = len(s)
s1 = s[:int((n-1)/2)]
s2 = s[int((n+3)/2-1):]

def isk(st):
    return st == st[::-1]

print(isk(s) and isk(s1) and isk(s2))

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

def isk(st):
    return st == st[::-1]

print("Yes" if (isk(s) and isk(s1) and isk(s2)) 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):
string = input()

def palindrome(inp):
  if inp == inp[::-1]: return True
  else: return False
  
if palindrome(string) and palindrome(string[:int((len(string) + 1)/2)] and palindrome(string[int((len(string) +3)/2):]: print("Yes")
else: print("No")

string = input()

def palindrome(inp):
  if inp == inp[::-1]: return True
  else: return False

if palindrome(string) and palindrome(string[:int((len(string) -1)/2)]) and palindrome(string[int((len(string) +1)/2):]): 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()
l = len(s)
c = (l-1)//2

count = 0
check = 0
for i in range(0,c-1):
  if s[i] == s[l-i-1]:
    count = count + 1
    
if count == c-1:
  check = check + 1

count1 = 0  
for j in range(0, c-1):
  if s[j] == s[c-j-1]:
    count1 = count1 + 1

if count1 == c-1:
  check = check + 1

print(check)
if check == 2:
  print('Yes')
else:
  print('No')


s = input()
l = len(s)
c = (l-1)//2

count = 0
check = 0
for i in range(0,c-1):
  if s[i] == s[l-i-1]:
    count = count + 1
    
if count == c-1:
  check = check + 1

count1 = 0  
for j in range(0, c-1):
  if s[j] == s[c-j-1]:
    count1 = count1 + 1

if count1 == c-1:
  check = check + 1

if check == 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()
judge = True
for i in range(len(S)//2):
    if S[i] != S[len(S) - i - 1]:
        judge = False
        break


if judge:        
    for i in range(int((len(S)-1)/2)):
  
        if S[i] != S[int((len(S)-1)/2)- 1 - i]:
            judge = False
            break
        elif S[int((N+3)/2)-1 + i] != S[N-1-i]:
            judge = False
            break

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

S = input()
judge = True
for i in range(len(S)//2 + 2):
    if S[i] != S[len(S) - i - 1]:
        judge = False
        break


if judge:        
    for i in range(int((len(S)-1)/2)):
  
        if S[i] != S[int((len(S)-1)/2)- 1 - i]:
            judge = False
            break
        elif S[int((N+3)/2)-1 + i] != S[N-1-i]:
            judge = False
            break

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

S = input()
N = len(S)
judge = True
for i in range(len(S)//2):
    if S[i] != S[len(S) - i - 1]:
        judge = False
        break


if judge:        
    for i in range(int((len(S)-1)/2)):
  
        if S[i] != S[int((len(S)-1)/2)- 1 - i]:
            judge = False
            break
        elif S[int((N+3)/2)-1 + i] != S[N-1-i]:
            judge = False
            break

if judge:
    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 = list(input())
N = len(S)
S2 = S[:(N-1)//2+2]
if S == S[::-1] and S2 == S2[::-1]:
    print('Yes')
else:
    print('No')

S = input()
N = len(S)
S2 = S[:(N-1)//2]
if S == S[::-1] and S2 == S2[::-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):
# input
S = input()


N = len(S)

print(f"{S}\t{S[:int((N - 1) / 2)]}\t{S[int((N + 2) / 2):]}")

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

# input
S = input()


N = len(S)

if S[:int((N - 1) / 2)] == S[int((N + 2) / 2):]:
    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 = list(input())
d = int((len(s)-1) / 2)
e = int((len(s)+3) / 2)
if s == s[::-1] and s[0:d-1] == s[0:d-1:-1] and s[e-1:] == s[e-1::-1]:
  print('Yes')
else:
  print('No')

s = input()
d = int((len(s)-1) / 2)
e = int((len(s)+3) / 2)
if s == s[::-1] and s[0:d] == s[d-1::-1] and s[e-1:] == s[int(len(s)):e-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):
s=input()
a=1
for i in range(len(s)):
  if(s[i]!=s[-i-1]):
    a=0
    break
for i in range((len(s)-1)//2):
  if(s[i]!=s[(len(s)-3)//2]):
    a=0
    break
if(a==1):
  print("Yes")
else:
  print("No")

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

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

Verdicts: Wrong Answer

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 = list(str(input()))

ans = 0
n = len(s)
s1 = list(reversed(s))
if s != s1:
    ans = 1

s2 = s[0:(n-1)//2]
s3 = list(reversed(s2))
if s2 != s3:
    ans = 1

s4 = s[(n+2)//2:n]
s5 = list(reversed(s4))
if s4 != s5:
    ans = 1

print(s,s1,s2,s3,s4,s5)

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

s = list(str(input()))

ans = 0
n = len(s)
s1 = list(reversed(s))
if s != s1:
    ans = 1

s2 = s[0:(n-1)//2]
s3 = list(reversed(s2))
if s2 != s3:
    ans = 1

s4 = s[(n+2)//2:n]
s5 = list(reversed(s4))
if s4 != s5:
    ans = 1

if ans == 0:
    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()
t = s[:int((len(s)-1)/2)]
u = s[(int(len(s)+3)/2-1):]
if s == s[::-1] and t == t[::-1] and u == u[::-1]:
  print("Yes")
else:
  print("No")

s = input()
t = s[:int((len(s)-1)/2)]
u = s[(int((len(s)+3)/2)-1):]
if s == s[::-1] and t == t[::-1] and u == u[::-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):
import sys
input = sys.stdin.readline

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

N1 = (N-1)/2
N2 = (N+3)/2

s1 = S[:N]
s2 = S[:N1]
s3 = S[N2-1:N]


import sys
input = sys.stdin.readline

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

import sys
input = sys.stdin.readline

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


N1 = (N-1)/2
N2 = (N+3)/2

s1 = S[:N]
s2 = S[:N1]
s3 = S[N2-1:N]

flag = True
for ss in [s1, s2, s3]:
    ss_l = len(ss)
    for i in range(ss_l):
        if ss[i] != ss[ss_l-i-1]:
            flag = False
            break
    if not flag:
        break

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



import sys
input = sys.stdin.readline

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

N1 = (N-1)/2
N2 = (N+3)/2

s1 = S[:N]
s2 = S[:N1]
s3 = S[N2-1:N]

flag = True
for ss in [s1, s2, s3]:
    ss_l = len(ss)
    for i in range(ss_l):
        if ss[i] != ss[ss_l-i-1]:
            flag = False
            break
    if not flag:
        break

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



import sys
input = sys.stdin.readline

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

N1 = int((N-1)/2)
N2 = int((N+3)/2)

s1 = S[:N]
s2 = S[:N1]
s3 = S[N2-1:N]

flag = True
for ss in [s1, s2, s3]:
    ss_l = len(ss)
    for i in range(ss_l):
        if ss[i] != ss[ss_l-i-1]:
            flag = False
            break
    if not flag:
        break

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



Verdicts: Runtime Error

Wrong Answer

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 = list(input())
n = len(s)
s_half = (n - 1)/2
s_3 = (n + 3)/ 2
if s == s[::-1]:
	if s[s_half - 1] == s[s_half - 1::-1]:
		if s[s_3 -1] == s[s_3 -1::-1]:
			print('Yes')
print('No')



s = list(input())
n = len(s)
s_half = (n - 1)/2
s_3 = (n + 3)/ 2
if s == s[::-1]:
	if s_half == s_half[::-1]:
		if s_3 == s_3[::-1]:
			print('Yes')
print('No')

s = input()
l = len(s)
if list(s) != list(reversed(s)):
    print('No')
    exit()
if list(s[:(l - 1) // 2]) != list(reversed(s[:(l - 1) // 2])):
    print('No')
    exit()
if list(s[(l + 3) // 2 -1:l]) != list(reversed(s[(l + 3) // 2 -1:l])):
    print('No')
    exit()
print('Yes')

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()
N=len(S)
S1=S[:(N+1)/2]
S2=S[(N+3)/2:]
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)/2):]
if S == S[::-1] and S1 == S1[::-1] and S2 == S2[::-1]:
  print("Yes")
else:
  print("No")

S=input()
N=len(S)
S1=S[:int((N-1)/2)]
S2=S[int((N+1)/2):]
if S == S[::-1] and S1 == S1[::-1] and S2 == S2[::-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):
data = input()
S = [c for c in data]
S_inverse = list(reversed(S))

N = len(S)

print(S[: int((N - 1) / 2)])
print(S_inverse[int((N + 3) / 2 - 1):])
print(S_inverse[: int((N - 1) / 2)])
print(S[int((N + 3) / 2 - 1):])

if S != S_inverse:
    print("No1")
    exit(0)

if S[: int((N - 1) / 2)] != S_inverse[int((N + 3) / 2 - 1):]:
    print("No2")
    exit(0)

if S[int((N + 3) / 2 - 1):] != S_inverse[:int((N - 1) / 2)]:
    print("No3")
    exit(0)

print("Yes")


data = input()
S = [c for c in data]
S_inverse = list(reversed(S))

print(S)
print(S_inverse)

if S != S_inverse:
    print("No")
    exit(0)

N = len(S)
if S[: int((N - 1) / 2)] != S_inverse[int((N + 3) / 2):]:
    print("No")
    exit(0)

if S[int((N + 3) / 2):] != S_inverse[:int((N - 1) / 2)]:
    print("No")
    exit(0)

print("Yes")


data = input()
S = [c for c in data]
S_inverse = list(reversed(S))

N = len(S)

if S != S_inverse:
    print("No")
    exit(0)

if S[: int((N - 1) / 2)] != S_inverse[int((N + 3) / 2 - 1):]:
    print("No")
    exit(0)

if S[int((N + 3) / 2 - 1):] != S_inverse[:int((N - 1) / 2)]:
    print("No")
    exit(0)

print("Yes")


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()

s_r = s[::-1]
N = len(s)
s_2 = s[:int((N-1)/2)]
s_3 = s[int((N+1)/2):]
print(s_r, s_2, s_3)
if ( (s == s_r) & (s_2 ==s_2[::-1]) &(s_3 ==s_3[::-1])):
  print('Yes')
else :
  print('No')
  

s= input()

s_r = s[::-1]
N = len(s)
s_2 = s[:int((N-1)/2)]
s_3 = s[int((N+1)/2):]

if ( (s == s_r) & (s_2 ==s_2[::-1]) &(s_3 ==s_3[::-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):
import math
import sys 
s = input()
if s==s[::-1]:
    n = len(s)
    right = int((n-1)/2)
    print(right)
    tmp = s[:right]
    if tmp == tmp[::-1]:
        left = int((n+3)/2)
        tmp2 = s[left-1:]
        if tmp2 == tmp2[::-1]:
            print('Yes')
            sys.exit()
print('No')


import math
import sys 
s = input()
if s==s[::-1]:
    n = len(s)
    right = int((n-1)/2)
    tmp = s[:right]
    if tmp == tmp[::-1]:
        left = int((n+3)/2)
        tmp2 = s[left-1:]
        if tmp2 == tmp2[::-1]:
            print('Yes')
            sys.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):
def is_kaibun(kaibun):
    for i in range(len(kaibun)//2):
        if kaibun[i] != kaibun[-i-1]:
            return False
    return True
  
s = input()

s_1 = s[:(len(s)-1)/2]
s_2 = s[(len(s)-3)/2:]

if is_kaibun(s) and is_kaibun(s_1) and is_kaibun(s_2):
  print('Yes')
else:
  print('No')

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

s_1 = s[:(int)((len(s)-1)/2)]
s_2 = s[(int)((len(s)+3)/2)-1:len(s)]

if is_kaibun(s) and is_kaibun(s_1) and is_kaibun(s_2):
  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):
import sys
s=input()
s_pre = s[:(n-1)//2]
s_epi = s[(n+1)//2:]
n = len(s)
if s != s[::-1]:
    print('No')
    sys.exit()
if s_pre != s_pre[::-1]:
    print('No')
    sys.exit()
if s_epi != s_epi[::-1]:
    print('No')
    sys.exit()
print('Yes')

import sys
s=input()
n=len(s)
s_pre = s[:(n-1)//2]
s_epi = s[(n+1)//2:]
if s != s[::-1]:
    print('No')
    sys.exit()
if s_pre != s_pre[::-1]:
    print('No')
    sys.exit()
if s_epi != s_epi[::-1]:
    print('No')
    sys.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):
s=list(input())
N=len(s)
tmp=s[0:int((N-1)/2)+1]
tmp_rev=tmp[::-1]

tmp2=s[int((N+3)/2)-1:]
tmp2_rev=tmp2[::-1]

if tmp==tmp_rev and tmp2==tmp2_rev:
  print("Yes")
else:
  print("No")

s=list(input())
N=len(s)
if N==3:
  if s[0]==s[2]:
    print("Yes")
  else:
    print("No")
else:
  tmp=s[0:int((N-1)/2)+1]
  tmp_rev=tmp[::-1]

  tmp2=s[int((N+3)/2)-1:]
  tmp2_rev=tmp2[::-1]

  if tmp==tmp_rev and tmp2==tmp2_rev and s==s[::-1]:
    print("Yes")
  else:
    print("No")

s=list(input())
N=len(s)
tmp=s[0:int((N-1)/2)+1]
tmp_rev=tmp[::-1]

tmp2=s[int((N+3)/2):N+1]
tmp2_rev=tmp2[::-1]

if tmp==tmp_rev and tmp2==tmp2_rev:
  print("Yes")
else:
  print("No")

s=list(input())
N=len(s)
tmp=s[0:int((N-1)/2)+1]
tmp_rev=tmp[::-1]

tmp2=s[int((N+3)/2)-1:]
tmp2_rev=tmp2[::-1]

if tmp==tmp_rev and tmp2==tmp2_rev and s==s[::-1]:
  print("Yes")
else:
  print("No")

s=list(input())
N=len(s)
if N==3:
  if s[0]==s[2]:
    print("Yes")
  else:
    print("No")
else:
  tmp=s[0:int((N-1)/2)]
  tmp_rev=tmp[::-1]

  tmp2=s[int((N+3)/2)-1:]
  tmp2_rev=tmp2[::-1]

  if tmp==tmp_rev and tmp2==tmp2_rev and s==s[::-1]:
    print("Yes")
  else:
    print("No")

Verdicts: Wrong Answer

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):
# -*- coding: utf-8 -*-
import sys
S = input()
S_list = list(S)
tmp = S_list.copy()
N = len(S)
if N % 2 == 0:
  print("No")
  sys.exit()
else: 
  S_list.reverse()
  if S_list == tmp:
    tmp_2 = int((len(tmp)-1) / 2)
    tmp_2_list = tmp[:tmp_2]
    t2=tmp_2_list.copy()
    
    tmp_3 = int((len(tmp)+3) / 2)
    tmp_3_list = tmp[tmp_3-1:]
    t3 = tmp_3_list.copy()
    
    tmp_2_list.reverse()
    tmp_3_list.reverse()
    if tmp_2_list == t2 and tmp_3_list == t3:
      print("yes")
      sys.exit()
    else:
      print("No")
      sys.exit()
  else:
    print("No")
    sys.exit()

# -*- coding: utf-8 -*-
import sys
S = input()
S_list = list(S)
tmp = S_list.copy()
N = len(S)
if N % 2 == 0:
  print("No")
  sys.exit()
else: 
  S_list.reverse()
  if S_list == tmp:
    tmp_2 = int((len(tmp)-1) / 2)
    tmp_2_list = tmp[:tmp_2]
    t2=tmp_2_list.copy()
    
    tmp_3 = int((len(tmp)+3) / 2)
    tmp_3_list = tmp[tmp_3-1:]
    t3 = tmp_3_list.copy()
    
    tmp_2_list.reverse()
    tmp_3_list.reverse()
    if tmp_2_list == t2 and tmp_3_list == t3:
      print("Yes")
      sys.exit()
    else:
      print("No")
      sys.exit()
  else:
    print("No")
    sys.exit()

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()
a = (len(n) - 1)//2
b = (len(n) + 3)//2
if n == n[::-1]:
  if n[0:a-1] == n[0:a-1:-1]:
    if n[b-1:len(n)-1] == n[b-1:len(n)-1:-1]:
      print("Yes")
  	else:
      print("No")
  else:
    print("No")
else:
  print("No")
    

n = input()
a = ((len(n) - 1)//2)
b = ((len(n) + 3)//2)-1
if n == n[::-1]:
    if n[:a] == n[-a::]:
        if n[b:] == n[:-b]:
            print("Yes")
        else:
            print("No")
    else:
        print("No")
else:
    print("No")

Verdicts: Runtime Error

Accepted