Skip to content

Instantly share code, notes, and snippets.

View mwakaba2's full-sized avatar

Mariko Wakabayashi mwakaba2

View GitHub Profile
mwakaba2 /
Last active May 9, 2021 22:49
Script to reproduce the `AsyncLibraryNotFoundError` error.
import os
from anyio.to_thread import run_sync
except ImportError:
# fallback on anyio v2 for python version < 3.7
from anyio import run_sync_in_worker_thread as run_sync
import asyncio
mwakaba2 /
Last active February 17, 2024 12:28
Updated easy to remember system design numbers for back-of-the-envelope calculations

Updated, easy to remember numbers for back-of-the-envelope calculations in system design interviews

Powers of two table

Power    Approx Value (Bytes)       Bytes
10                 1 thousand        1 KB
16                65 thousand       64 KB
20                  1 million        1 MB
30 1 billion 1 GB