There are piles.
You, Alice, and Bob take turns collecting piles according to the following rules:
In each round, you choose any
Alice picks the pile containing the maximum number of coins.
You pick the pile containing the next maximum number of coins.
Bob picks the remaining pile.
This process repeats until no piles of coins remain.
Return the maximum number of coins that you can collect.
Constraints:
piles.length
piles.length
piles[i]
There are piles.
You, Alice, and Bob take turns collecting piles according to the following rules:
In each round, you choose any
Alice picks the pile containing the maximum number of coins.
You pick the pile containing the next maximum number of coins.
Bob picks the remaining pile.
This process repeats until no piles of coins remain.
Return the maximum number of coins that you can collect.
Constraints:
piles.length
piles.length
piles[i]