Ukje is an avid fan of Gusagwa. Today Ukje wants to hand a gift to Gusagwa. After watching for several days, Ukje has learned the complete movement pattern of Gusagwa.
The place where Gusagwa stays is a rectangular map of size 1×N, divided into N square cells of size 1×1. The position of Gusagwa is written as (1,x), which means the xth cell from the left.
Each cell holds either E or W. When Gusagwa is at (1,x), Gusagwa teleports to (1,x+1) if the cell shows E and to (1,x−1) if it shows W. Gusagwa never gets tired and keeps moving.
Ukje does not know the starting position of Gusagwa. Ukje wants to place gifts on cells so that Gusagwa picks up a gift during the walk no matter where the walk starts. When Gusagwa enters a cell with a gift, Gusagwa always picks it up. Write a program that finds the smallest number of cells that guarantees this.