Credit for this problem goes to the 51st IMO, problem 5. Thanks!

## Coin Towers

In each of six boxes \(B_1\), \(B_2\), \(B_3\), \(B_4\), \(B_5\), \(B_6\) there is initially one coin. There are two types of operation allowed:

**Type 1:** Choose a nonempty box \(B_j\) with \(1 \leq j \leq 5\). Remove one coin from \(B_j\) and add two coins to \(B_{j+1}\).

**Type 2:** Choose a nonempty box \(B_k\) with \(1 \leq k \leq 4\). Remove one coin from \(B_k\) and exchange the contents of (possibly empty) boxes \(B_{k+1}\) and \(B_{k+2}\).

**Warm up problem:** Using only operations of Type 1, what’s the most coins you can have in total across all 6 boxes?

**Main problem:** Using operations of either type, what’s the most coins you can have in total across all 6 boxes?