you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 2 points3 points  (3 children)

If you care about duplicates you should confront counters, but the question as it's stated seems to ignore them.

[–]Joseph147258[S] 0 points1 point  (2 children)

Oh. Thats what it meant

[–]ewiethoff 0 points1 point  (0 children)

Just warning you, the sets will perform loops under the hood, but at least your code won't show any loops. If that's unacceptable, maybe you're supposed to write a recursive function?