Ilang months from your travel date do you book your accommodation?

Same question with activities. Hehe. Thanks!