Two to One

From by Edxael  (that’s me)

Instructions:  Take 2 strings s1 and s2 including only letters from ato z. Return a new sorted string, the longest possible, containing distinct letters, – each taken only once – coming from s1 or s2.


My solution:

Note:  The following code is not written by me, it was created by another user of it belongs to the user: “Beast” enjoy.


Copyright 2017. All rights reserved.

Posted December 31, 2016 by Edmundo in category "Ruby Examples