Plan Cloud Migration Waves From an Application Dependency Map

Last updated: November 29, 2026

Quick Overview

Given a client's applications and a list of dependencies where an app can move only after its prerequisites, group the applications into the fewest ordered migration waves, and report a cycle if no valid plan exists.

Accenture
Coding & Algorithms
Software Engineer
Accenture
November 29, 2026
Software Engineer
Technical Screen
Coding & Algorithms
Medium

0

0

0 solved


Given a client's applications and a list of dependencies where an app can move only after its prerequisites, group the applications into the fewest ordered migration waves, and report a cycle if no valid plan exists.

Cloud migration planning (the kind of analysis Accenture's myNav tooling supports) starts from a dependency map of a client's estate. The interviewer checks that the candidate recognizes topological sorting, produces level-by-level waves rather than a single order, and gives an actionable error on cycles.

What the Interviewer Expects
  • Models the estate as a directed graph with edges prerequisite to dependent
  • Uses Kahn's algorithm level by level to form waves
  • Explains why level order gives the minimum number of waves
  • Detects cycles and names the apps involved
  • Produces deterministic output for review with the client
Key Topics to Cover
Topological sort
Kahn's algorithm
Cycle detection
Graph modeling
Cloud migration planning
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
  • How would you cap each wave at a maximum number of apps or a maximum risk score?
  • Real dependency maps have cycles, such as two apps calling each other. How would you plan around them?
  • How would you minimize the number of cross-environment network calls during the transition?
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: list of app names and (app, prerequisite) pairs. Output: list of waves, each a sorted list of apps, such that every prerequisite sits in an earlier wave. Minimize the number of waves. If a cy...

High-Level Design

Build a graph with an edge from prerequisite to dependent and track in-degree. Wave 1 is every app with in-degree 0. Removing a wave decrements its children; any child that drops to 0 joins the next w...


Submit Your Answer
Markdown supported

Related Questions