jhylands

Swimming with Snakes pt3

Jul 26th, 2020
1,341
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.20 KB | None | 0 0
  1. def pad_last(board):
  2.     r = len(board.keys())
  3.     for i in range(r):
  4.         if round(sum(board[i].values()),6)!=1:
  5.             board[i][r-1] = 1 + board[i][r-1]-sum(board[i].values())
  6.     return board
  7.  
Advertisement
Add Comment
Please, Sign In to add comment