#22027: Python 80%求解~~~~~~~~`


edion6666@gmail.com (Coding intern~)


請問各位高手,還需加甚麼條件?

import math
a,b,c=input().split()
a=int(a);b=int(b);c=int(c)
md=(b**2)-(4*a*c)
if md >=0:
  md_=math.sqrt(md)
  x=(-b+md_)/2*a
  y=(-b-md_)/2*a
  if md==0:
    print("Two same roots x="+str(int(x)))
  elif md>0:
    print("Two different roots x1="+str(int(x)),",","x2="+str(int(y)))
elif md<0:
  print("No real root")