#include <bits/stdc++.h>
using namespace std;
const int N = 1e6;
bool used[N];
vector<complex<long long> > points;
long long n;
long long cross(complex<long long> a, complex<long long> b) {
  return (conj(a) * b).imag();
}
void get_collinear(complex<long long> p1, complex<long long> p2) {
  for (long long i = 0; i < n; i++) {
    if (not used[i]) {
      if (cross(p2 - p1, points[i] - p1) == 0) {
        used[i] = true;
      }
    }
  }
}
long long get_next() {
  for (long long i = 0; i < n; i++) {
    if (not used[i]) {
      return i;
    }
  }
  return -1;
}
int32_t main() {
  ios::sync_with_stdio(0);
  cin >> n;
  for (long long i = 0; i < n; i++) {
    long long x, y;
    cin >> x >> y;
    points.emplace_back(x, y);
  }
  if (n <= 4) {
    cout << "YES" << endl;
    return 0;
  }
  vector<long long> indexes = {0, 1, 2};
  do {
    complex<long long> p1 = points[indexes[0]];
    complex<long long> p2 = points[indexes[1]];
    complex<long long> p3 = points[indexes[2]];
    get_collinear(p1, p2);
    bool all = true;
    long long nxt = get_next();
    if (nxt == -1) {
      cout << "YES" << endl;
      return 0;
    }
    complex<long long> p4 = points[nxt];
    used[nxt] = true;
    nxt = get_next();
    if (nxt == -1) {
      cout << "YES" << endl;
      return 0;
    }
    complex<long long> p5 = points[nxt];
    get_collinear(p4, p5);
    long long ans = get_next();
    if (ans == -1) {
      cout << "YES" << endl;
      return 0;
    }
    for (long long i = 0; i < n; i++) used[i] = false;
  } while (next_permutation(indexes.begin(), indexes.end()));
  cout << "NO" << endl;
  return 0;
}
