Question: solve using any programming language - Choose three packages with the same weight Determine the minimum number of trips required to deliver the packages. If

solve using any programming language
- Choose three packages with the same weight Determine the minimum number of trips required to deliver the packages. If it is not possible to deliver all of them, return - 1 . Example weights =[2,4,6,6,4,2,4] The agent needs a minimum of 3 trips as shown below. Return 3 as the answer. Remaining First Trip \begin{tabular}{|l|l|l|l|l|} \hline 4 & 6 & 6 & 4 & 4 \\ \hline \end{tabular} Second Trip Third Trip
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
