In building C of ADA University, one prepares a very tasty and healthy multivitamin juice. One dose of juice requires a apples, b pears, and c oranges. However, there is bad luck — you must bring the fruits for juice with you!
Huseyn likes multivitamin juice very much. He currently has x apples, y pears, and z oranges. What is the maximum number of juice doses he can order?
The first line contains three integers a,b, and c. The second line contains three integers x,y, and z. All numbers are non-negative integers not greater than 109.
Print the largest number of juice doses that Huseyn can order.