#include <bits/stdc++.h>
using namespace std;
const int ms = 123456;
int n;
struct Point {
  long long x, y;
  Point(long long a = 0, long long b = 0) {
    x = a;
    y = b;
  }
  Point operator-(const Point &a) { return Point(x - a.x, y - a.y); }
  void read() { cin >> x >> y; }
  long long operator%(const Point &a) { return x * a.y - y * a.x; }
};
Point v[ms];
bool colinear(Point a, Point b, Point c) { return (c - a) % (b - a) == 0; }
bool solve(Point a, Point b) {
  vector<Point> temp;
  for (int i = 0; i < n; i++)
    if (!colinear(a, b, v[i])) temp.push_back(v[i]);
  for (int i = 2; i < temp.size(); i++)
    if (!colinear(temp[0], temp[1], temp[i])) return false;
  return true;
}
int main() {
  cin >> n;
  for (int i = 0; i < n; i++) v[i].read();
  if (solve(v[0], v[1]) || solve(v[0], v[2]) || solve(v[1], v[2]))
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
