
Sponsored
Sponsored
Use these hints if you're stuck. Try solving on your own first.
Use Dynamic Programming
Let ways[i][points] be the number of ways to score a given number of points after solving some questions of the first i types.
ways[i][points] is equal to the sum of ways[i-1][points - solved * marks[i] over 0 <= solved <= count_i