Snap | Phone Screen | 2022 | Graph question
Anonymous User
918

Location: Seattle, WA

Your organization is running multiple services on Google Cloud. Recently, a decision has been made to migrate these services to AWS.
Since a service can depend on other downstream services, it cannot be migrated until all of its downstream dependencies are migrated too.
Given the following API, implement a function that computes one possible migration path.

interface ServiceRepo {
	// Gives all services in existence
	ListString> listServiceNames();
	ListString> getServiceDependencies(String serviceName);
}

Similar questions: Web Crawler

Comments (3)