Problem #362
Big Josephus
There are n balloons in a cyclic room numbered from 1 to n (Balloon 2 comes after 1, Balloon 3 comes after 2, \dots, Balloon 1 comes after Balloon n). You start at 1. Every turn you skip one balloon and pop the next balloon until there is only one balloon left.
Let F(n) denote the number on the last remaining balloon. Find the sum of F(1) + F(2) + F(3) + \dots + F(182721378) and submit the answer modulo 10^9 + 7.