python input quadratic formula

Solutions on MaxInterview for python input quadratic formula by the best coders in the world

showing results for - "python input quadratic formula"
Kelsey
03 Nov 2020
1import math
2print(' ')
3print('welcome to bright\'s quadratic formula calculator')
4print('please put in the following values')
5print(' ')
6
7a = input('a value:\n')
8b = input('b value:\n')
9c = input('c value:\n')
10
11a=float(a)
12b=float(b)
13c=float(c)
14
15print((-b + math.sqrt(b ** 2 - 4*a*c))/2*a)
16print((-b - math.sqrt(b ** 2 - 4*a*c))/2*a)