Tom was uncertain whether he should donate his money or save it to buy a Gameboy.
When he was in the deep thinking of this question, he saw a little girl putting some money into the donation box.
Hi,
Is it better to rewrite the bolded part as "
When he was wrapped/absorbed in this problem?" Thanks.