Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #1
- a = int('1000100110101011', 2)
- print(oct(a)[2:])
- #2
- print('С -', 10)
- print('О - 010')
- print('К -', 11)
- print(1001011)
- #1
- def DEL(n, m):
- return n % m == 0
- def f(x, A):
- return (not DEL(x, A)) <= (DEL(x, 6) <= (not DEL(x, 9)))
- for A in range(1000, 0, -1):
- #print(A)
- true_is_A = True
- for x in range(1, 1000):
- if not f(x, A):
- true_is_A = False
- if true_is_A:
- print(A)
- break
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement