Sichanov

multiply by 2

Apr 30th, 2021
241
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.16 KB | None | 0 0
  1. number = float(input())
  2. while number >= 0:
  3.     number = number * 2
  4.     print(f'{number:.2f}')
  5.     number = float(input())
  6.  
  7. else:
  8.     print('Negative number!')
Advertisement
Add Comment
Please, Sign In to add comment