Farz0l1x

Untitled

Feb 12th, 2023
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.28 KB | None | 0 0
  1. a = [0] * 1000
  2. a[102] = 1
  3. for i in range(102, 43, -1):
  4.     if i - 8 >= 43:
  5.         a[i + 8] += a[i]
  6.     if i // 2 >= 43:
  7.         a[a * 2] += a[i]
  8. for i in range(43, 5, -1):
  9.     if i - 8 >= 5:
  10.         a[i+8] += a[i]
  11.     if i // 2 >= 5:
  12.         a[i*2] += a[i]
  13. print(a[18])
Advertisement
Add Comment
Please, Sign In to add comment