Skip to content

Instantly share code, notes, and snippets.

View Eleazar-Harold's full-sized avatar
🏠
Working from home

eleazar yewa harold Eleazar-Harold

🏠
Working from home
View GitHub Profile
def get_unique(m:list):
c = {}
for i in m:
if c.get(i) is not None:
c.pop(i)
c[i] = i
return next(iter(c.values()))
assert get_unique([6,1,3,3,3,6,6]) == 1
assert get_unique([13,19,13,13]) == 19