Finding the imaginary part of the complex number
imaginary = s [ i + 1 : l - 1 ] NEW_LINE x = int ( real ) NEW_LINE y = int ( imaginary ) NEW_LINE if ( x > 0 and y > 0 ) : NEW_LINE INDENT print ( " Quadrant ▁ 1" ) NEW_LINE DEDENT elif ( x < 0 and y > 0 ) : NEW_LINE INDENT print ( " Quadrant ▁ 2" ) NEW_LINE DEDENT elif ( x < 0 and y < 0 ) : NEW_LINE INDENT print ( " Quadrant ▁ 3" ) NEW_LINE DEDENT elif ( x > 0 and y < 0 ) : NEW_LINE INDENT print ( " Quadrant ▁ 4" ) NEW_LINE DEDENT elif ( x == 0 and y > 0 ) : NEW_LINE INDENT print ( " Lies ▁ on ▁ positive " , " Imaginary ▁ axis " ) NEW_LINE DEDENT elif ( x == 0 and y < 0 ) : NEW_LINE INDENT print ( " Lies ▁ on ▁ negative " , " Imaginary ▁ axis " ) NEW_LINE DEDENT elif ( y == 0 and x < 0 ) : NEW_LINE INDENT print ( " Lies ▁ on ▁ negative " , " X - axis " ) NEW_LINE DEDENT elif ( y == 0 and x > 0 ) : NEW_LINE INDENT print ( " Lies ▁ on ▁ positive " , " X - axis " ) NEW_LINE DEDENT else : NEW_LINE INDENT print ( " Lies ▁ on ▁ the ▁ Origin " ) NEW_LINE DEDENT