1p3a_oj Question

Compute Total Size of a File System (Tree/Graph)

Question Details

Given a file system hierarchy, compute the total size starting from a given root directory. Each node is either a directory or a file: A file has a non-negative integer size. A

Full Details

🔒

Unlock all Google questions

Full insider details, leaked discussions, and candidate experiences.

or every company, $100/year →

About This Question

This is a reported interview question from a google interview for a swe role during the coding round.

It covers the following topics: Trees, Dynamic Programming, Graph, Graphs, System Design .

Difficulty rating: Hard