//Problem "Convex"
//10th Internet Olympiad, season 2007-2008
//Problem Author:  Fedor Tsarev, tsarev@rain.ifmo.ru
//Solution Author: Vladimir Ulyantsev, ulyantsev@rain.ifmo.ru

import java.io.*;
import java.util.*;
import java.math.*;

public class convex_vu_slow {

	public static void main(String[] args) throws IOException {
		Scanner in = new Scanner(new File("convex.in"));
		PrintWriter out = new PrintWriter(new File("convex.out"));
		
		int n = in.nextInt();
		long[] x = new long[n];
		long[] y = new long[n];
		for (int i = 0; i < n; i++) {
			x[i] = in.nextInt();
			y[i] = in.nextInt();
		}

		boolean ans = true;
		for (int i = 0; i < n; i++) {
			for (int j = 0; j < n; j++) {
				long x1 = x[(i + 1) % n] - x[i];
				long y1 = y[(i + 1) % n] - y[i];
				long x2 = -x[(i + 1) % n] + x[j];
				long y2 = -y[(i + 1) % n] + y[j];
				if (x1 * y2 - x2 * y1 < 0) {
					ans = false;
				}
			}
		}
		if (ans) {
			out.print("YES");
		} else {
			out.print("NO");
		}

		in.close();
		out.close();
	}

}