Advertisement
Guest User

Untitled

a guest
Sep 19th, 2019
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.28 KB | None | 0 0
  1. def printTransition(mod, base):
  2. for n in range(mod):
  3. for t in range(base):
  4. result = (n * base + t) % mod
  5. print(f'({n} * {base} + {t}) % {mod} = {result}')
  6. print(f'{n} --{t}--> {result}')
  7.  
  8. printTransition(3, 2)
  9. print()
  10. printTransition(6, 2)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement