Skip to content

Instantly share code, notes, and snippets.

@kangeugine
Created August 2, 2018 15:32
Show Gist options
  • Select an option

  • Save kangeugine/7078a58cdcc3839f71d58fb5a8db43b3 to your computer and use it in GitHub Desktop.

Select an option

Save kangeugine/7078a58cdcc3839f71d58fb5a8db43b3 to your computer and use it in GitHub Desktop.

Revisions

  1. kangeugine created this gist Aug 2, 2018.
    5 changes: 5 additions & 0 deletions fantasy-football-constraints-2.py
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,5 @@
    def constraint_unique(x):
    n1 = x.size
    n2 = np.unique(to_int(x)).size
    return n1 - n2
    # if constraint_unique(x) == 0, test passed