24 lines
272 B
Plaintext
Executable File
24 lines
272 B
Plaintext
Executable File
main()
|
|
|
|
def main()
|
|
|
|
"enter a:"
|
|
|
|
a = input()
|
|
|
|
"enter b:"
|
|
b = input()
|
|
|
|
"enter c:"
|
|
c = input()
|
|
|
|
disc = pow(b,2) - 4*a*c
|
|
|
|
x1 = (-b - sqrt(disc) ) / (2*a)
|
|
x2 = (-b + sqrt(disc) ) / (2*a)
|
|
|
|
"x1: " print(x1) "\n"
|
|
"x2: " print(x2 ) "\n"
|
|
|
|
end
|