</>OfferRetriever
DashboardDiscuss
NEW

Spring Hire Sale

Limited Time Deal: Unlock all premium questions for over 30% off

$10.42$7.08

08

:

03

:

10

:

14

Get this deal
Back to Dashboard

Asset Tree Size

Medium

You are given a list of asset nodes representing a tree structure and a target path. Each node has a name, an optional size (present only for leaf assets), and an optional list of children (present for directory nodes). Find the node with the given path name and return the total size of all leaf assets under it (including itself if it is a leaf).

Each node is an object with: ...