Advertisement
Guest User

Untitled

a guest
Oct 20th, 2017
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.43 KB | None | 0 0
  1. import sys
  2. import math
  3.  
  4. # Auto-generated code below aims at helping you parse
  5. # the standard input according to the problem statement.
  6. a=0
  7. b=0
  8. for i in input().split():
  9.     x = int(i)
  10.     a+=x
  11. for i in input().split():
  12.     x = int(i)
  13.     b+=x
  14.    
  15. # Write an action using print
  16. # To debug: print("Debug messages...", file=sys.stderr)
  17.  
  18. d=a-b
  19.  
  20. if d > 0:
  21.     print(d*-1)
  22. elif d < 0:
  23.     print(d*-1)
  24. else:
  25.     print(d)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement