class TypoGen::SwapLetter
Public Class Methods
create(word)
click to toggle source
# File lib/typogen/swap_letter.rb, line 3 def self.create(word) (word.size-1).times.map do |i| temp = word.dup temp[i], temp[i+1] = temp[i+1], temp[i] temp end.uniq end