2698. Find the Punishment Number of an Integer - Explanation

Problem Link