Created
April 17, 2014 23:25
-
-
Save priteshgupta/11016997 to your computer and use it in GitHub Desktop.
RF2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def func(): | |
| out = [] | |
| ar1 = [1, 27, 50, 49, 51, 99, 51, 51] | |
| for i1 in ar1: | |
| for i2 in ar1: | |
| if i1 + i2 == 100: | |
| out.append(tuple(sorted((i1, i2)))) | |
| out = set(out) | |
| for i in out: | |
| print(i) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment