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):
##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        gv.s = input()
    
    def string_reverse_chk(gv, s:str):
        rev_s :_= ''.join(reversed(s))
        if s == rev_s:
            return True
        return False
    
    def solve(gv):
        pass
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()



##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        gv.s = input()
    
    def string_reverse_chk(gv, s:str):
        rev_s = ''.join(reversed(s))
        if s == rev_s:
            return True
        return False
    
    def solve(gv):
        
        ans = "No"
        
        while True:
            reversed_s = "".join(reversed(gv.s))
            slen = len(gv.s)
            
            if gv.string_reverse_chk(gv.s) is False : break
        
            if gv.string_reverse_chk(gv.s[0:int((slen -1)/2)]) is False : break
            if gv.string_reverse_chk(reversed_s[0:int((slen -1)/2)]) is False : break
        
            if gv.string_reverse_chk(gv.s[int((slen +3)/2 -1):slen]) is False : break
            if gv.string_reverse_chk(reversed_s[int((slen +3)/2 -1):slen]) is False : break
            
            
            ans = "Yes"
            break
        
        print(ans)
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()


##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        pass
    
    def string_reverse_chk(gv, s:str):
        rev_s :_= ''.join(reversed(s))
        if s == rev_s:
            return True
        return False
    
    def solve(gv):
        pass
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()




##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        gv.s = input()
    
    def string_reverse_chk(gv, s:str):
        rev_s :_= ''.join(reversed(s))
        if s == rev_s:
            return True
        return False
    
    def solve(gv):
        
        ans:_ = "No"
        
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()



##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        gv.s = input()
    
    def string_reverse_chk(gv, s:str):
        rev_s :_= ''.join(reversed(s))
        if s == rev_s:
            return True
        return False
    
    def solve(gv):
        
        ans:_ = "No"
        
        while True:
            reversed_s = "".join(reversed(gv.s))
            slen :_= len(gv.s)
            
            if gv.string_reverse_chk(gv.s) is False : break
        
            if gv.string_reverse_chk(gv.s[0:int((slen -1)/2)]) is False : break
            if gv.string_reverse_chk(reversed_s[0:int((slen -1)/2)]) is False : break
        
            if gv.string_reverse_chk(gv.s[int((slen +3)/2 -1):slen]) is False : break
            if gv.string_reverse_chk(reversed_s[int((slen +3)/2 -1):slen]) is False : break
            
            
            ans = "Yes"
            break
        
        print(ans)
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()


##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        gv.s = input()
    
    def string_reverse_chk(gv, s:str):
        rev_s = ''.join(reversed(s))
        if s == rev_s:
            return True
        return False
    
    def solve(gv):
        
        ans:_ = "No"
        
        while True:
            reversed_s = "".join(reversed(gv.s))
            slen = len(gv.s)
            
            if gv.string_reverse_chk(gv.s) is False : break
        
            if gv.string_reverse_chk(gv.s[0:int((slen -1)/2)]) is False : break
            if gv.string_reverse_chk(reversed_s[0:int((slen -1)/2)]) is False : break
        
            if gv.string_reverse_chk(gv.s[int((slen +3)/2 -1):slen]) is False : break
            if gv.string_reverse_chk(reversed_s[int((slen +3)/2 -1):slen]) is False : break
            
            
            ans = "Yes"
            break
        
        print(ans)
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()


##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        gv.s = input()
    
    def string_reverse_chk(gv, s:str):
        rev_s :_= ''.join(reversed(s))
        pass
    
    def solve(gv):
        pass
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()





##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        gv.s = input()
    
    def string_reverse_chk(gv, s:str):
        rev_s = ''.join(reversed(s))
        pass
    
    def solve(gv):
        pass
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()






##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        gv.s = input()
    
    
    
    def solve(gv):
        pass
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()




##======================================python3
import sys
import collections
sys.setrecursionlimit(10**6)
input = sys.stdin.readline

class Run:
    def build(gv):
        gv.s = input().strip()
    
    def string_reverse_chk(gv, s:str):
        rev_s = "".join(list(reversed(s))[0:len(s)])
        if s == rev_s:
            return True
        return False
    
    def solve(gv):
        
        ans = "No"
        
        while True:
            slen = len(gv.s)
            reversed_s = "".join(list(reversed(gv.s))[0:slen])
            
            if gv.string_reverse_chk(gv.s) is False : break
            if gv.string_reverse_chk(gv.s[0:int((slen -1)/2)]) is False : break
            if gv.string_reverse_chk(reversed_s[0:int((slen -1)/2)]) is False : break
            
            if gv.string_reverse_chk(gv.s[int((slen +3)/2 -1):slen]) is False : break
            if gv.string_reverse_chk(reversed_s[int((slen +3)/2 -1):slen]) is False : break
            
            
            ans = "Yes"
            break
        
        print(ans)
        
if __name__ == '__main__':
    run = Run()
    run.build()
    run.solve()


Verdicts: Runtime Error

Wrong Answer

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Wrong Answer

Wrong Answer

Accepted