Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- s = input()
- a = int(s.split('x')[0])
- b = int(s.split('+')[1].split('=')[0])
- if a == 0 and b != 0:
- print('no solutions')
- elif b == 0:
- print('0')
- elif b != 0 and ((-b / a) != 0):
- print(int(-b / a))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement