John has some coins of the denomination of 1,2 and 3$. He has X 1$ coins, Y 2$ coins, and Z 3$coins. John visits a toy shop where there are N types of toys. It is given that the ith toy has a price tag of Aj John can buy a toy if he can pay for John wants to buy just one toy. Your task is to help John figure out the total number of toys in the store that John can choose to buy. Note: It is guaranteed that John will not buy more than one toy from the store. Input Format The first line contains an integer, N, denoting the number of elements in A. The next line contains an integer, X, denoting the 1$ coins John has. The next line contains an integer, Y, denoting the 2$ coins John has.
Answers
Answered by
0
Answer:
teachoo.com/13599/766/Ex-13.4--4-iii/category/Ex-13.4/
Explanation:
Similar questions