Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added .DS_Store
Binary file not shown.
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ Create a `Player` class with a minimum of 11 specs. The class should have the fo
- `#highest_scoring_word`: Returns the highest scoring word the user has played.
- `#highest_word_score`: Returns the `highest_scoring_word` score.

<!--

## Wave 3

### Primary Requirements
Expand Down Expand Up @@ -117,4 +117,3 @@ Beginning Tile Quantities:
- Create a `Dictionary` class that includes a method for searching a list of words to determine if a given word is a valid word.
- Create a `Board` class that has a matrix (array of arrays) of tile places. Check if a word can be played on a given tile place in a certain direction.
- Include a minimum of 20 specs between the `Dictionary` and `Board` classes.
-->
Binary file added lib/.DS_Store
Binary file not shown.
18 changes: 18 additions & 0 deletions lib/dictionary.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
module ScrabbleMod

class Dictionary

def find_word(word)
if word.is_a? String
File.open("./lib/en.txt") do |f|
f.any? do |line|
line.include?(word)
end
end
else
return false
end
end

end
end
Loading