add longest duplicated string.rb