Posts by Rodrigo Conde Attanasio • 1 point
1 post
-
0
votes2
answers259
viewsA: I’m trying to do Bhaskara in Python and even with the highlighted if programming says I can’t turn a Complex into float
I did so: def bhaskara(a,b,c): delta = (b**2)-(4*a*c) print (str(delta) + " delta") x1 = (-b + math.sqrt(delta))/(2*a) print (str(x1) + " valor de 'X1'") x2 = ((-b - math.sqrt(delta))/(2*a)) print…
pythonanswered Rodrigo Conde Attanasio 1