The question is why would you want to use pointers in such a situation. To me Number should obviously always be allocated on stack.