UVA 674 - Coin Change UVA • Sep 1, 2020 Problem PDFSolution:#include #include long long Mod = 100000007; int main() { long long coin[6]={1,5,10,25,50},way[7510]={0},i,j,a; way[0]=1; for(i=0;i<5;i++) { for(j=coin[i];j<=7500;j++) { way[j]+=way[j-coin[i]]; if(way[j]>=Mod) way[j]%=Mod; } } while(scanf("%lld",&a)==1) { printf("%lld\n",way[a]); } return 0; } https://github.com/Shipu/OnlineJudgeProblemSolutionWithCPlusPlus/tree/master/uva/674/674.cpp Tags UVA Competitive Programming Shipu Ahamed Recommended for you UVA UVA 913 - Joana and the Odd Numbers 4 years ago • 1 min read UVA UVA 871 - Counting Cells in a Blob 4 years ago • 3 min read UVA UVA 866 - Intersecting Line Segments 4 years ago • 3 min read