Johnny and the Beanstalk

can anyone explain Johnny and the Beanstalk problem? because the tutorial is not explain [link text][1]

question said that " At any level(including the 1st), a stem can end (forming exactly one leaf), or branch into exactly two stems which grow into the next level, " but tutorial said that “The number of leaves at the last level is an even number (because the number of stems at any level will be twice the number of stems brought over from the previous level AND all stems at the last level will be converted to leaves).” which is true? admin can you explain or all others users

hey u got your answer or not??
see this one…

(CodeChef: Practical coding for everyone)
I am get the 1st test case wrong here. I don’t know why?