There are six people on the island who all want to go across the river. Each of them spend different times to ride the raft between these islands individually. Their riding times (all with same time units) are \(\{X_1, X_2, X_3, X_4, X_5, X_6\}\), where these positive integers of \(X\)'s are all strictly increasing multiples in that order.

Your goal is to get all people across the river as efficient as possible, given the following rules:

- At most two people can get on the raft at a time.
- The time to travel from an island to another with two people is \(\max\left(X_i, X_j\right)\), where \(1 \leq i \neq j \leq 6\) are some integers. Otherwise, the time spent is determined by a person who rides the raft.
- All people can go to and from either shore as many times as they need.

What is the minimum total time length to bring all people to another island?

**Assumption:** Neglect the amount of time elapsed between rides and before the first ride.

×

Problem Loading...

Note Loading...

Set Loading...