dxnge

20

Oct 20th, 2021
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.29 KB | None | 0 0
  1. #в 7 сс 6665555 (a +1*3) (b+1*4)
  2. print(6*7**6 + 6*7**5 + 6*7**4 + 5*7**3 + 5*7**2 + 5*7 + 5)
  3. print(int('6665555', 7))
  4.  
  5. x = int(input()) #823142
  6. a, b = 0, 0
  7. while x > 0:
  8.     d = x % 7
  9.     if d % 2 == 0:
  10.         a += 1
  11.     else:
  12.         b += 1
  13.     x = x // 7
  14. print(a)
  15. print(b)
  16.  
Advertisement
Add Comment
Please, Sign In to add comment