Anonymous · shared experience1 Oct 2025 · 5 views
Coupang: In-memory file system with append and sorted listing
Problem. Implement a file system interface with these operations:
- Create a directory.
- Write to a file: create it with the content if missing, otherwise append the content.
- Read (cat) a file.
- List the direct children of a directory in lexicographic order.
Approach. A trie of path segments where each node is either a directory (a sorted map of children) or a file (a content buffer) covers all four operations.
Comments 0
No comments yet. Ask the author something, or add what happened in your own round.