right:recursion
right:about stack
right:about stack and it is vary artifice
wrong:time limit out but the result is right