I am trying to solve this problem https://www.hackerrank.com/challenges/coin-change/problem I am getting WA on 8 testcases , but am not able to point out my mistake . My dp state seems fine to me. Can someone please help me find my mistake in this code . Thanks in advance :) Link to my code https://ideone.com/WpjdKJ