#include <bits/stdc++.h>
using namespace std;
long long int ar[100005][2];
int take[100005];
struct dat {
  int d1;
  int d2;
  int d3;
  int d4;
};
int main() {
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> ar[i][0] >> ar[i][1];
  }
  if (n <= 4) {
    printf("YES\n");
  } else {
    vector<int> pick;
    for (int i = 0; i < n && pick.size() < 4; i++) {
      if (pick.size() == 0) {
        pick.push_back(i);
        take[i] = 1;
      } else {
        long long int x = ar[i][0];
        long long int y = ar[i][1];
        int check = 1;
        long long int deltax;
        long long int deltay;
        long long int compx;
        long long int compy;
        for (int j = 0; j < pick.size(); j++) {
          deltax = x - ar[pick[j]][0];
          deltay = y - ar[pick[j]][1];
          for (int k = 0; k < pick.size(); k++) {
            if (j == k) continue;
            compx = ar[pick[k]][0] - ar[pick[j]][0];
            compy = ar[pick[k]][1] - ar[pick[j]][1];
            if ((compx == 0 && deltax == 0) || (compy == 0 && deltay == 0)) {
              check = 0;
            }
            if (compy != 0 && compx != 0 && deltax != 0 && deltay != 0 &&
                (double)deltay * compx == (double)deltax * compy) {
              check = 0;
            }
            if (check == 0) break;
          }
          if (check == 0) break;
        }
        if (check == 1) {
          pick.push_back(i);
          take[i] = 1;
        }
      }
    }
    dat temp;
    vector<dat> lis;
    vector<int> val;
    int z = pick.size();
    for (int i = 0; i < z; i++) {
      for (int j = 0; j < z; j++) {
        if (i == j) continue;
        for (int k = 0; k < z; k++) {
          for (int l = 0; l < z; l++) {
            if (k == l) continue;
            temp.d1 = pick[i];
            temp.d2 = pick[j];
            temp.d3 = pick[k];
            temp.d4 = pick[l];
            lis.push_back(temp);
            val.push_back(1);
          }
        }
      }
    }
    for (int i = 0; i < n; i++) {
      long long int x = ar[i][0];
      long long int y = ar[i][1];
      long long int deltax;
      long long int deltay;
      long long int compx;
      long long int compy;
      int check = 0;
      for (int j = 0; j < lis.size(); j++) {
        if (val[j] == 1) {
          int check = 0;
          deltax = x - ar[lis[j].d1][0];
          deltay = y - ar[lis[j].d1][1];
          compx = ar[lis[j].d2][0] - ar[lis[j].d1][0];
          compy = ar[lis[j].d2][1] - ar[lis[j].d1][1];
          if (i == lis[j].d1 || i == lis[j].d2 || i == lis[j].d3 ||
              i == lis[j].d4) {
            check = 1;
          }
          if ((compx == 0 && deltax == 0) || (compy == 0 && deltay == 0)) {
            check = 1;
          }
          if (compy != 0 && compx != 0 && deltax != 0 && deltay != 0 &&
              (double)deltay * compx == (double)deltax * compy) {
            check = 1;
          }
          deltax = x - ar[lis[j].d3][0];
          deltay = y - ar[lis[j].d3][1];
          compx = ar[lis[j].d4][0] - ar[lis[j].d3][0];
          compy = ar[lis[j].d4][1] - ar[lis[j].d3][1];
          if ((compx == 0 && deltax == 0) || (compy == 0 && deltay == 0)) {
            check = 1;
          }
          if (compy != 0 && compx != 0 && deltax != 0 && deltay != 0 &&
              (double)deltay * compx == (double)deltax * compy) {
            check = 1;
          }
          val[j] = check;
        }
      }
    }
    int cor = 0;
    for (int i = 0; i < lis.size(); i++) {
      if (val[i] == 1) {
        cor = 1;
        break;
      }
    }
    if (cor)
      printf("YES\n");
    else
      printf("NO\n");
  }
}
