Closed flbulgarelli closed 7 years ago
I do not like the name unique.
could work for a pure one.
On Thu, Sep 15, 2016 at 12:35 AM, Franco Leonardo Bulgarelli < notifications@github.com> wrote:
I have already see asSet().asList() idiom in many students solutions. So we need a method for removing duplicates in lists, without converting them into sets. It could be as simple as:
method unique() = asSet().asList()
It could be a method with or without effects, it is not so important for me. An effectful method could be named removeDuplicates or something like that.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/uqbar-project/wollok/issues/983, or mute the thread https://github.com/notifications/unsubscribe-auth/AEa1OV0q5HbnY57mB6l8ts2IC03RwgDXks5qqHbNgaJpZM4J9Uc9 .
Ok, withoutDuplicates
sounds good for a pure method!
I have already see
asSet().asList()
idiom in many students solutions. So we need a method for removing duplicates in lists, without converting them into sets. It could be as simple as:It could be a method with or without effects, it is not so important for me. An effectful method could be named
removeDuplicates
or something like that.