Han Solo and Lazer Gun

题意翻译

# 题目描述 有n个恐怖分子在站在一个平面上,每个恐怖分子都有一个位置坐标位置(x,y) 。现在有一个激光武器要用来消灭这些恐怖分子,这个武器所在的位置是(x0,y0),激光武器每发射一次,就可以消灭一条直线上的所有恐怖分子。 现在,你的任务是计算最少要动用多少次激光武器,才可以消灭所有的恐怖分子。 # 输入输出数据 ## 输入数据 第一行是3个整数n和x0,y0,分别表示恐怖分子的数量和武器所在的位置。(1<=n<=1000,-10000<=x0,y0<=1000) 接下来N行,每行两个整数表示每个恐怖分子的坐标位置Xi和Yi,恐怖分子可能站在相同的位置,但是不可能站在武器的位置上。(-10000<=xi<=10000) ## 输出数据 输出最少需要使用激光武器的次数。 # 说明 样例1和样例2的情况如图所示: ![](https://cdn.luogu.org/upload/vjudge_pic/CF514B/e0665254dc28c85d59225f8c53a8542938957367.png)

题目描述

There are $ n $ Imperial stormtroopers on the field. The battle field is a plane with Cartesian coordinate system. Each stormtrooper is associated with his coordinates $ (x,y) $ on this plane. Han Solo has the newest duplex lazer gun to fight these stormtroopers. It is situated at the point $ (x_{0},y_{0}) $ . In one shot it can can destroy all the stormtroopers, situated on some line that crosses point $ (x_{0},y_{0}) $ . Your task is to determine what minimum number of shots Han Solo needs to defeat all the stormtroopers. The gun is the newest invention, it shoots very quickly and even after a very large number of shots the stormtroopers don't have enough time to realize what's happening and change their location.

输入输出格式

输入格式


The first line contains three integers $ n $ , $ x_{0} $ и $ y_{0} $ ( $ 1<=n<=1000 $ , $ -10^{4}<=x_{0},y_{0}<=10^{4} $ ) — the number of stormtroopers on the battle field and the coordinates of your gun. Next $ n $ lines contain two integers each $ x_{i} $ , $ y_{i} $ ( $ -10^{4}<=x_{i},y_{i}<=10^{4} $ ) — the coordinates of the stormtroopers on the battlefield. It is guaranteed that no stormtrooper stands at the same point with the gun. Multiple stormtroopers can stand at the same point.

输出格式


Print a single integer — the minimum number of shots Han Solo needs to destroy all the stormtroopers.

输入输出样例

输入样例 #1

4 0 0
1 1
2 2
2 0
-1 -1

输出样例 #1

2

输入样例 #2

2 1 2
1 1
1 0

输出样例 #2

1

说明

Explanation to the first and second samples from the statement, respectively: ![](https://cdn.luogu.com.cn/upload/vjudge_pic/CF514B/e0665254dc28c85d59225f8c53a8542938957367.png)