Skip to content

Instantly share code, notes, and snippets.

@tugrul
Created March 7, 2022 19:14
Show Gist options
  • Select an option

  • Save tugrul/40c981b36b82b94833ca0b412ac8a78e to your computer and use it in GitHub Desktop.

Select an option

Save tugrul/40c981b36b82b94833ca0b412ac8a78e to your computer and use it in GitHub Desktop.

Revisions

  1. tugrul created this gist Mar 7, 2022.
    3 changes: 3 additions & 0 deletions abn.py
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,3 @@
    find = lambda number, max: len([n for n in (a/b for a,b in (((a*b),(a+b)) for a in range(1,max) for b in range(1, max)) if a != 0 or b != 0) if n == number])

    print(find(7, 1000))