Justin likes beans. In fact, he likes beans so much he wants to make a bean stew. There are different bean species and Justin has beans of the species.
Justin's bean stew recipe requires beans of the species to make. Justin is very hungry, so help him find out how many bean stews he can possibly make!
Input Specification
The first line contains a single integer , the number of bean species.
The next line contains space separated integers , where represents how many beans of the species Justin has.
The final line contains space separated integers , where represents how many beans of the species is required by the bean stew recipe.
Output Specification
Output a single integer representing the total number of bean stews Justin can make.
Sample Input
3
7 10 2
2 4 1
Sample Output
2
Explanation for Sample Output
Making bean stews takes beans of the species, beans of the species and beans of the species. Justin doesn't have enough ingredients to make any more stews after that.
Comments