Search
⌘K

Leetcode 568. Maximum Vacation Days

Given a flights graph and a matrix of vacation days per city per week, start at city 0 and choose each week whether to stay or fly along allowed edges to maximize total vacation days over K weeks. The core challenge is a DP/state-search over (city, week) states with transitions constrained by the flight graph and time steps to accumulate the optimal sum.

Asked at:

Meta

Datadog


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Late August, 2025

Meta

Senior

Vacation and PTO days

Early May, 2025

Meta

Staff

Mid April, 2025

Datadog

Mid-level

# You work in an international company with an odd travel policy. # If you are in country X when there’s a national holiday, # you get that day off for free (doesn’t count against your vacation quota). # Assuming you can only travel on weekends, compute a travel schedule that maximizes your vacation days. # Follow up with least city changes

Comments

Your account is free and you can post anonymously if you choose.