team needs 14 runs to win In a match a team needs 14 runs to win in the last over to win the match
(i.e.) exactly 14 run, assuming that all runs are made off the bat and the batsmen can not score more than 4 runs off any ball. find the number of ways in which team just manages to win the match i.e.  scores exactly 14 runs.
My attempt to the solution
We can take 3 cases 
2 dot balls
1 dot balls
0 dot balls
Only the 1st case is easy to solve next are very difficult to calculate.

If I understand the question, you want the number of ways of choosing six integers $a_1,\ldots,a_6$ with $0 \le a_i \le 4$ and $\sum_1^6 a_i = 14$. The answer is the coefficient of $x^{14}$ in the polynomial $(x^4+x^3+x^2+x+1)^6$, which you can ask Wolfram Alpha to compute.
This assumes that you don't need to have the team win the match on the very last ball.
