# [Perl 5], 21 +2 (-ap) = 23 bytes <!-- language-all: lang-perl --> $_+=$F[0]while/[2-9]/ Run with `-a` and `-p`, input to stdin. Just keeps repeatedly adding the input for as long as the result contains any digits from 2 to 9. [Try it online!][TIO-k70jlxzb] [Perl 5]: https://www.perl.org/ [TIO-k70jlxzb]: https://tio.run/##K0gtyjH9/18lXttWxS3aILY8IzMnVT/aSNcyVv//f7N/@QUlmfl5xf91EwsA "Perl 5 – Try It Online"