Find the total no of ways

i would like to find the no of ways in which the value can be formed…is there any way to add any counter or any dp aaray that would calculate that

hi @PoojaSingh22 I think this article should solve your query. Please mark the doubt as resolved if you are satisfied.