Sha256: 409c2580cd30ab4567d7efd954571f6d0777bb5f2803e05b4a501add8b475440

Contents?: true

Size: 327 Bytes

Versions: 1

Compression:

Stored size: 327 Bytes

Contents

class WordScramble::ScrambledWord

  def initialize(scrambled_word)
    @scrambled_word = WordScramble::LetterFrequency.new(scrambled_word)
  end

  def can_make(word)
    WordScramble::LetterFrequency.new(word) == @scrambled_word
  end

  def length
    @scrambled_word.length
  end

  alias_method :can_make?, :can_make

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
word_scramble-0.1.0 lib/word_scramble/scrambled_word.rb