human
Check if any square ( with one colored cell ) can be divided into two equal parts | function to check if it 's possible to divide the square in two equal parts.
if the painted square is linked anyway to the center of the square then it 's  not possible.
else yes it 's possible.
Driver code.
initialize the size of the square.
initialize the dimension of the painted square"
How can the above be solved in Python?
 Write me a code to check if any square ( with one colored cell ) can be divided into two equal parts and the other steps required?
assistant
#Here is code to check if any square ( with one colored cell ) can be divided into two equal parts and the other steps required.
 def halfsquare ( n , x , y ) :
	half = n // 2
	if ( ( half == x or half == x - 1 ) and ( half == y or half == y - 1 ) ) :
		print ( " NO " )
	else :
		print ( " YES " )
if __name__ == " _ _ main _ _ " :
	n = 100
	x , y = 51 , 100
	halfsquare ( n , x , y )