P5977 [CEOI 2008] Fence

Description

In a $1000 \times 1000$ area, there are $n$ fixed points and $m$ trees. Now you want to build a fence to protect the trees. The cost to build it is: (the number of fixed points you choose) $\times 20$ + (the number of trees not enclosed by the fence) $\times 111$. You want this value to be as small as possible. Find the minimum cost.

Input Format

The first line gives $n, m$. The next $n$ lines give the coordinates of the fixed points. The next $m$ lines give the coordinates of the trees.

Output Format

Output the minimum cost.

Explanation/Hint

For $100\%$ of the testdata, $3 \le N, M \le 100$。 Translated by ChatGPT 5