#include<iostream>
#include<set>
#include<stdio.h>
#include<math.h>
#include<algorithm>
#define MAXN 705
using namespace std;
int num;
double p[MAXN][];
double a[MAXN*MAXN];
set<int> coll;
set<int>::iterator pos;
multiset<int> coll_main;
int main()
{
//freopen("acm.acm","r",stdin);
int i;
int max;
int j;
int k;
int t;
double value;
int num;
double s2;
scanf("%d",&num);
max = ;
for(i = ; i < num; ++ i)
{
scanf("%lf%lf",&p[i][],&p[i][]);
}
for(i = ; i < num; ++ i)
{
k = ;
for(j = ; j < num; ++ j)
{
if(i != j)
{
value = (p[i][] - p[j][]) / (p[i][] - p[j][]);
a[k] = value;
++ k;
}
}
sort(a,a + k);
s2 = a[];
j = ;
for(t = ; t < k; ++ t)
{
if(a[t] == s2)
++ j;
else
{
if(j > max)
{
max = j;
}
s2 = a[t];
-- t;
j = ;
}
}
if(j > max)
max = j;
}
++max;
cout<<max<<endl;
}

POJ 2606的更多相关文章

  1. 【同一直线最多点】 poj 1118+2606+2780

    poj 1118 #include<iostream> using namespace std; #define N 700 struct point {int x,y;} pnt[N]; ...

  2. POJ 3370. Halloween treats 抽屉原理 / 鸽巢原理

    Halloween treats Time Limit: 2000MS   Memory Limit: 65536K Total Submissions: 7644   Accepted: 2798 ...

  3. POJ 2356. Find a multiple 抽屉原理 / 鸽巢原理

    Find a multiple Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 7192   Accepted: 3138   ...

  4. POJ 2965. The Pilots Brothers' refrigerator 枚举or爆搜or分治

    The Pilots Brothers' refrigerator Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 22286 ...

  5. POJ 1753. Flip Game 枚举or爆搜+位压缩,或者高斯消元法

    Flip Game Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 37427   Accepted: 16288 Descr ...

  6. POJ 3254. Corn Fields 状态压缩DP (入门级)

    Corn Fields Time Limit: 2000MS   Memory Limit: 65536K Total Submissions: 9806   Accepted: 5185 Descr ...

  7. POJ 2739. Sum of Consecutive Prime Numbers

    Sum of Consecutive Prime Numbers Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 20050 ...

  8. POJ 2255. Tree Recovery

    Tree Recovery Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 11939   Accepted: 7493 De ...

  9. POJ 2752 Seek the Name, Seek the Fame [kmp]

    Seek the Name, Seek the Fame Time Limit: 2000MS   Memory Limit: 65536K Total Submissions: 17898   Ac ...

随机推荐

  1. MySQL按日、周、月统计数据

    知识关键词:DATE_FORMAT ps:如果时间字段为时间戳则,DATE_FORMAT(from_unixtime(create_time),'%Y-%u') select DATE_FORMAT( ...

  2. IPython:一种交互式计算和开发环境

    IPython基础 可以通过命令行启动IPython,执行任何Python语句,只需将其输入然后回车. Tab键自动完成 在Shell中输入表达式时,只要按下Tab键,当前命名空间中任何与已输入的字符 ...

  3. hdu-1034(模拟+小朋友分糖)

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1034 参考文章:https://blog.csdn.net/zyy173533832/article/ ...

  4. rpcbind.service启动失败

    新装的服务器,启动rpcbind.service通常失败,执行下面的两个命令经常卡死,一直不返回,也不报错 #systemctl start nfs-server.service #systemctl ...

  5. C(m,n)算法

    排列组合:C(m,n),m为给定数列,n为要从数列m中取元素的数量,GetResult()获取所有不重复的组合. public class MathCombination<T> { Lis ...

  6. QOpenGLFunctions的使用(2)

    QOpenGLFunctions的使用(2) 前一小结请参考:QOpenglFuncations(1) www.icmzn.com 本小节介绍相关的类: 1. The QGLContext class ...

  7. 省赛在即!最大流问题回顾学习!!DInic

    Dinic是很好的算法,但是我还是从ek算法复习起步 面对最大流问题,印象最深的就是反向边的思想,他给我们提供了反悔的机会,其实现在放到实际上来想,可以相当于两边的水都流了这条边,只是方向不一样,放到 ...

  8. scikit-FEM-例1-求解Possion边值问题

    """ Author: kinnala Solve the problem -∇²u = 1 with zero boundary conditions on a uni ...

  9. cxgrid显示海量数据

    cxgrid显示海量数据 在默认情况下,cxgrid显示几万条以上的数据会很慢.怎么办? 交下面的属性设为TRUE以后,速度飞快. 但速度是快了,自动计算列的合计值这些功能却失效了,正所谓有得必有失!

  10. Ubuntu下mount命令的好用处

    mount,也就是挂载.如果是让电脑自己挂载Windows的分区,也就是你直接在文件管理器里点击那些Windows的盘符,系统就会帮助你自动挂载,不过其挂载后的名称太长太复杂,不方便终端操作.所以还是 ...