Python sets and dictionaries can have quadratic-time performance

·Hacker News··

In Python, the dict data structure is the conventional key-value structure. E.g., you might store a list of names as keys and have their phone numbers as values. Valentin Ignatev wrote this amusing post on X: It is indeed widely believed that, in the strict sense, the dict data structure and its companion, the set … Continue reading Python sets and dictionaries can have quadratic-time performance

Read full article →

Related Articles

Anthropic S-1
SiNTEx · Hacker News · 18h ago
Solar power is becoming bigger than nuclear
geox · Hacker News · 16h ago
The Exponential Time Hypothesis Is False [pdf]
vok · Hacker News · 9h ago
Oldest GUI application that still runs on Windows 11
enlyth · Hacker News · 13h ago
Type Server Protocol
adamnemecek · Hacker News · 13h ago