// Source code from laekov at noip 2015 day2 #define PRID “stone” #include #include #include

using namespace std;

const int maxn = 50003;

int n, m, l, a[maxn];

int checkStone(int lt) { int s(0), po(0); for (int i = 0; i < n; ++ i) if (a[i] - po >= lt) po = a[i]; else ++ s; if (l - po < lt) ++ s; return s; }

int main() { freopen(PRID “.in”, “r”, stdin); freopen(PRID “.out”, “w”, stdout);

scanf("%d%d%d", &l, &n, &m);
for (int i = 0; i < n; ++ i)
	scanf("%d", a + i);
int le(0), re(l);
while (le < re) {
	int md((le + re + 1) >> 1);
	if (checkStone(md) > m)
		re = md - 1;
	else
		le = md;
}
printf("%d\n", le);

}