This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from typing import Callable, Union | |
| # ascii is [0, 128) | |
| MAX_CHAR = 0x80 | |
| EPSILON = 0 | |
| class RegEx: | |
| # dummy reference so mmap isn't freed before we're done | |
| coderef: Buffer |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from string import ascii_lowercase | |
| from typing import Dict, Set | |
| import requests | |
| ascii_set = set(ascii_lowercase) | |
| words = list(filter(lambda x: len(x) == 5 and len(set(x)) == 5 and len(set(x).intersection(set('aeiou'))) < 2, requests.get('https://raw.githubusercontent.com/dwyl/english-words/master/words_alpha.txt').text.split())) | |
| adj_list: Dict[str, Set[str]] = dict() | |
| letters_dict: Dict[str, Set[str]] = dict() | |
| for letter in ascii_lowercase: |