projects
/
riddle-generator.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
45d6b76
)
Removed neighbour generation out of the core library
main
author
Neil Smith
<NeilNjae@users.noreply.github.com>
Fri, 8 Sep 2023 09:55:42 +0000
(10:55 +0100)
committer
Neil Smith
<NeilNjae@users.noreply.github.com>
Fri, 8 Sep 2023 09:55:42 +0000
(10:55 +0100)
riddle_definitions.md
patch
|
blob
|
history
diff --git
a/riddle_definitions.md
b/riddle_definitions.md
index da25f927c3eafc5f76b6ec1fc974e998a23d6f65..1db01f7b1bcc338759f74ee6f8e6a9569b2622e3 100644
(file)
--- a/
riddle_definitions.md
+++ b/
riddle_definitions.md
@@
-121,19
+121,6
@@
def edit_distance(s: str, t: str) -> int:
return res
```
return res
```
-```python
-dictionary_neighbours = {
- w: [o for o in dictionary
- if edit_distance(w, o) <= 5
- if not set(w) <= set(o)
- if not set(o) <= set(w)]
- for w in dictionary}
-
-dictionary_neighbours = {w: ns
- for w, ns in dictionary_neighbours.items()
- if ns}
-```
-
```python
def collapse_riddle_clues(elems : Riddle) -> RiddleElems:
"""Combine the two parts of a riddle line into one element for solving.
```python
def collapse_riddle_clues(elems : Riddle) -> RiddleElems:
"""Combine the two parts of a riddle line into one element for solving.