Your Dashboard
Interview Coaching
Learn
System Design
ML System Design
Code
Behavioral
Salary Negotiation
Interview Guides
Search
⌘K
Get Premium
Leetcode 2739. Total Distance Traveled
Compute the total usable fuel when every time 5 liters are consumed from the main tank an instantaneous 1-liter transfer occurs from the additional tank if available, and return the maximum distance given the truck runs 10 km per liter. This reduces to counting how many extra 1-liter transfers can happen (bounded by additionalTank) and multiplying total usable liters by 10.
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
All Regions
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.