+ 2

I'm writing math codes that are useful to me, but how can I let someone else assign a value to a variable in my codes?

25th Feb 2017, 3:28 PM
Slitherboy
Slitherboy - avatar
8 ответов
+ 1
Thanks man
25th Feb 2017, 3:36 PM
Slitherboy
Slitherboy - avatar
+ 1
I tried it, but it didn't work for multiple variables. How would I get that to work like a, b, and c
25th Feb 2017, 3:39 PM
Slitherboy
Slitherboy - avatar
+ 1
a = int(input("Assisgn value of a: ")) b = int(input("Assisgn value of b: ")) c = int(input("Assisgn value of c: ")) print((-b + (b ** 2 - 4 * a * c) ** .5) / 2 / a) print((-b - (b ** 2 - 4 * a * c) ** .5) / 2 / a) There is my code but it says I need to split into different lines and I'm not sure what to do.
25th Feb 2017, 3:58 PM
Slitherboy
Slitherboy - avatar
0
Could you show me by editing my code
25th Feb 2017, 4:02 PM
Slitherboy
Slitherboy - avatar