import std.stdio;
import std.conv;
import std.string;
import std.typecons;
import std.algorithm;
import std.array;
import std.range;
import std.math;
import std.container;
import std.datetime;

void main()
{
	while (1) {
		auto x = readln.chomp.split.map!(to!int);
		if (!x[0]) break;
		auto area = new bool[][](61, 61);
		foreach (_; 0..x[1]) {
			auto y = readln.chomp.split.map!(to!int);
			area[y[0]+30][y[1]+30] = 1;
		}
		int cnt;
		alias Tuple!(int, int, int) Data;
		Data[] list;
		auto q = DList!(Data)(list);
		auto s = readln.chomp.split.map!(to!int);
		Data data;
		data[0] = s[0] + 30;
		data[1] = s[1] + 30;
		data[2] = x[0];
		q.stableInsertBack(data);
		while (!q.empty) {
			auto t = q.front;
			auto i = t[0];
			auto j = t[1];
			auto n = t[2];
			q.stableRemoveFront;
			if (area[i][j]) continue;
			area[i][j] = 1;
			cnt++;
			if (!n) continue;
			foreach (a; iota(-1, 2, 2)) {
				if (i + a >= 0 && i + a < 61) {
					data[0] = i + a;
					data[1] = j;
					data[2] = n - 1;
					q.stableInsertBack(data);
				}
				if (j + a >= 0 && j + a < 61) {
					data[0] = i;
					data[1] = j + a;
					data[2] = n - 1;
					q.stableInsertBack(data);
				}
				if (i + a >= 0 && i + a < 61 && j + a >= 0 && j + a < 61) {
					data[0] = i + a;
					data[1] = j + a;
					data[2] = n - 1;
					q.stableInsertBack(data);
				}
			}
		}
		
		cnt.writeln;
	}
}