Daehyun
7/27/2017 - 1:00 PM

scramble.py

def scramble(arr):
    return arr.sum(1)[:, None] @ arr.sum(0)[None, :] / arr.sum()