Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # -*- coding: utf-8 -*-
- """
- Created on Sat Nov 21 17:06:32 2020
- @author: Sergey
- """
- a,b,c=float(input()),float(input()),float(input())
- D=(b**2)-4*a*c
- if D>0:
- print('x1 =',(-b+(D**(1/2)))/(2*a))
- print('x2 =',(-b-(D**(1/2)))/(2*a))
- elif D==0:
- print('x =', (-b)/(2*a))
- else:
- print('Нет действительных корней')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement