#P16283. [蓝桥杯 2026 省 Python A 组] 平面选点
[蓝桥杯 2026 省 Python A 组] 平面选点
Problem Description
In the Cartesian coordinate plane, the fixed point is the origin .
Now consider all lattice points whose -coordinate and -coordinate are both between and . Please count the number of point pairs that satisfy the following conditions:
- Both and are lattice points described above, and neither of them coincides with .
- .
- The area of the triangle formed by points is an integer.
If are collinear, the area of the triangle is defined as , and this case is also included in the answer.
The pair is unordered, meaning that and are considered the same pair.
Output Format
This is a fill-in-the-blank problem. You only need to compute the result and submit it. The result is an integer. When submitting, only fill in this integer; any extra content will result in no score.
Hint
Translated by ChatGPT 5