# Unlimited Fafnir

After watching the famous anime Unlimited Fafnir, XGN got excited. So he decided to recreate the scene of fighting the Basilisk.
This time, Yuu is going to do it himself. Let's suppose the world is a 2D plane. Then the Basilisk's heart is at location (a,b) and Yuu's weapon's attack range is c.
The Basilisk has 2 defense ways.

1. He can use his third eye to shoot laser at (d,e) with an attack range of f and the power of it is g

2. He can use his normal eye to shoot laser at (h,i) with an attack range of j and the power of it is k

We call someone at (a,b) can be hit by a weapon at (c,d) with attack range e iff \sqrt{(a-c)^2+(b-d)^2}\leq e
If Yuu is hit by one of the defenses Basilisk makes, he will lose some health, the amount of the health equals to the power.
Now Yuu wonders, what's the minimum amount of health to lose while he can hit Basilisk's heart.

# Example

a,b,c,d,e,f,g,h,i,j,k=8,4,4,14,0,10,2,6,6,6,1

# Constriants

0\leq |a|,|b|,c,|d|,|e|,f,g,|h|,|i|,j,k \leq 10^9

THE END