You are given an array tasks where tasks[i] = [actual, minimum]:
actual
minimum
For example, if a task is
You can finish the tasks in any order. Return the minimum initial amount of energy needed to finish all the tasks.
Constraints:
tasks.length
actualminimum
You are given an array tasks where tasks[i] = [actual, minimum]:
actual
minimum
For example, if a task is
You can finish the tasks in any order. Return the minimum initial amount of energy needed to finish all the tasks.
Constraints:
tasks.length
actualminimum