Compute Look-Through Exposure Across Nested Fund Holdings

Last updated: November 29, 2026

Quick Overview

A fund can hold securities and other funds, which can hold further funds. Given each fund's holdings as weights, compute the effective weight of every underlying security in a top-level fund, and detect cyclic holdings.

BlackRock
Coding & Algorithms
Software Engineer
BlackRock
November 29, 2026
Software Engineer
Onsite
Coding & Algorithms
Hard

0

0

0 solved


A fund can hold securities and other funds, which can hold further funds. Given each fund's holdings as weights, compute the effective weight of every underlying security in a top-level fund, and detect cyclic holdings.

Look-through analytics matter for funds of funds, target date funds built from iShares ETFs, and insurers who must report underlying exposure. The interviewer is looking for a graph traversal with memoization on a DAG, correct weight multiplication, and explicit cycle detection.

What the Interviewer Expects
  • Models holdings as a weighted directed graph
  • Multiplies weights along paths and sums across paths
  • Memoizes shared sub-funds so each is expanded once
  • Detects cycles with a visiting/done coloring
  • Discusses numeric stability and weights that do not sum to 1
Key Topics to Cover
DFS
memoization
cycle detection
weighted DAG
fund of funds
How to Approach This
  1. Clarify input constraints and edge cases before writing code.
  2. Walk through your approach verbally and confirm with the interviewer before coding.
  3. Start with a brute force solution, then optimize. Mention time and space complexity.
  4. Test your solution with examples, including edge cases like empty input or duplicates.
  5. Consider common patterns: sliding window, two pointers, hash map, BFS/DFS, dynamic programming.
Possible Follow-up Questions
  • Two funds legitimately hold each other through a share class. How would you solve it as a linear system?
  • How would you incrementally update exposures when one ETF's holdings change?
  • How would you look through to issuer or sector instead of security?
Sharpen Your Skills on Codemia

Practice similar problems with our interactive workspace, get AI feedback, and track your progress.

Practice DSA Problems
Sample Answer
Requirements

Input: holdings maps fund to a list of (child, weight); any child not in the map is a security. Output: security to effective weight in the root fund. If a fund appears inside its own holdings, ra...

High-Level Design

Treat it as a weighted DAG. The exposure of a fund is the weighted sum of its children's exposures, so a DFS that returns a dictionary per node works. Many funds share the same sub-fund (an S&P 500 ET...


Submit Your Answer
Markdown supported

Related Questions