Skip to content
Merged
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
4 changes: 2 additions & 2 deletions anagram/anagram.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@ def find_anagrams(word: str, candidates: list[str]) -> list[str]:
return [
candidate
for candidate in candidates
if candidate.lower() != target_lower
and sorted(candidate.lower()) == target_sorted
if (candidate_lower := candidate.lower()) != target_lower
and sorted(candidate_lower) == target_sorted
]