#include <bits/stdc++.h>
using namespace std;
double PointToArea(pair<long long, long long> p1, pair<long long, long long> p2,
                   pair<long long, long long> p3) {
  return (p1.first * (p2.second - p3.second) +
          p2.first * (p3.second - p1.second) +
          p3.first * (p1.second - p2.second));
}
bool isColleniar(pair<long long, long long> a, pair<long long, long long> b,
                 pair<long long, long long> c) {
  return PointToArea(a, b, c) == 0;
}
vector<pair<long long, long long> > p, p2;
bool TRY(pair<long long, long long> a, pair<long long, long long> b) {
  p2.clear();
  for (int i = 0; i < ((int)p.size()); ++i)
    if (not isColleniar(a, b, p[i])) p2.push_back(p[i]);
  for (int i = 2; i < ((int)p2.size()); ++i)
    if (not isColleniar(p2[0], p2[1], p2[i])) {
      return 0;
    }
  return 1;
}
int main() {
  int n;
  cin >> n;
  p.resize(n);
  for (int i = 0; i < n; ++i) cin >> p[i].first >> p[i].second;
  for (int i = 2; i < n; ++i)
    if (not isColleniar(p[0], p[1], p[i])) {
      swap(p[i], p[2]);
      break;
    }
  if (TRY(p[0], p[1]) or TRY(p[1], p[2]) or TRY(p[2], p[0]))
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
  return 0;
}
