#3259

Maximum Energy Boost From Two Drinks

specialist · 880 · lc medium +31 · 50% accepted · 180 likes · top 38%

Description

You are given integer arrays energyDrinkA and energyDrinkB of length n. Each hour you drink exactly one. Switching drinks costs one hour (no boost). Return the maximum total energy boost over n hours.

Code

1
2
3