#include <iostream>
#include <set>

using namespace std;

set <int> st;

int main() {
    int n, k, a, m;
    cin >> n >> k >> a >> m;

    set <int> :: iterator it, it2;

    int start, ender;

    long long ans = n / a;

    for (int i = 0; i < m; i++) {
        int b; cin >> b;

        it = st.lower_bound(b);

        if (it == st.end()) {
            ender = n + 1;
        } else {
            ender = *it;
        }

        if (it != st.begin())
            it--;

        if (it == st.begin()) {
            start = 0;
        } else {
            start = *it;
        }

        int y = (ender - start - 1) / a;
        int x = (b - start - 1) / a + (ender - b - 1) / a;
        ans = ans - y + x;

        if (ans < k) {
            cout << i + 1;
            return 0;
        }

        st.insert(b);
    }

    cout << -1;

    return 0;
}


#include <iostream>
#include <set>

using namespace std;

set <int> st;

int main() {
    int n, k, a, m;
    cin >> n >> k >> a >> m;

    set <int> :: iterator it, it2;

    int start, ender;
    long long ans = (n + 1) / (a + 1);

    for (int i = 0; i < m; i++) {
        int b; cin >> b;

        it = st.upper_bound(b);

        if (it == st.end()) {
            ender = n + 1;
        } else {
            ender = *it;
        }

        if (st.begin() == it) {
            start = 0;
        } else {
            it--;
            start = *it;
        }

        int y = (ender - start) / (a + 1);
        int x1 = (b - start) / (a + 1);
        int x2 = (ender - b) / (a + 1);
        ans = ans - y + x1 + x2;

        if (ans < k) {
            cout << i + 1;
            return 0;
        }

        st.insert(b);

        //cout << ans << " " << y << " " << x1 << " " << x2 << " :" << start << " " << ender << " " << st.size()<< endl;
    }

    cout << -1;

    return 0;
}


#include <iostream>
#include <set>

using namespace std;

set <int> st;

int main() {
    int n, k, a, m;
    cin >> n >> k >> a >> m;

    set <int> :: iterator it, it2;

    int start, ender;
    long long ans = (n + 1) / (a + 1);

    for (int i = 0; i < m; i++) {
        int b; cin >> b;

        it = st.upper_bound(b);

        if (it == st.end()) {
            ender = n + 1;
        } else {
            ender = *it;
        }

        if (it != st.begin())
            it--;

        if (st.begin() == st.end()) {
            start = 0;
        } else {
            start = *it;
        }

        int y = (ender - start) / (a + 1);
        int x1 = (b - start) / (a + 1);
        int x2 = (ender - b) / (a + 1);
        ans = ans - y + x1 + x2;

        if (ans < k) {
            cout << i + 1;
            return 0;
        }

        st.insert(b);

        //cout << ans << " " << x1 << " " << x2 << " :" << start << " " << ender << " " << st.size()<< endl;
    }

    cout << -1;

    return 0;
}


#include<bits/stdc++.h>
using namespace std;
#define maxn 200005
#define IOS ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int n,a,b,arr[maxn],m;

bool f(int x)
{  set<int>s;
 for(int i=1;i<=x;i++)
    s.insert(arr[i]);
    s.insert(m+1);
	int prev=0;
	int c=0;
	for(auto it= s.begin();it!=s.end();it++)
	{
    	int val=(*(it)-prev-1);
    	if(val%(b+1)==b)
    	 c+=(val/(b+1))+1;
    	else
    	c+= (val/(b+1));
		// cout<<prev<<" "<<*it<<" "<<c<<endl;
		prev=*it;
	}
	s.clear();
	if(c>=a)
	return false;
	return true;
}

main()
{ IOS
	cin>>m>>a>>b;
	cin>>n;
	for(int i=1;i<=n;i++)
	cin>>arr[i];

	int low=1,high=n;
//	cout<<f(18);
//	cout<<f(1)<<" "<<f(2)<<" "<<f(3)<<" "<<f(4)<<" "<<f(5)<<endl;
	while(low<high)
	{
		int mid = (low+high)/2;

		if(f(mid))
		high=mid;
		else
		low = mid+1;
	}
	if(f(low))
	cout<<low;
	else
	cout<<-1;

}


#include<bits/stdc++.h>
using namespace std;
#define maxn 200005
#define IOS ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int n,a,b,arr[maxn],m;

bool f(int x)
{  set<int>s;
 for(int i=1;i<=x;i++)
    s.insert(arr[i]);
    s.insert(m+1);
	int prev=0;
	int c=0;
	for(auto it= s.begin();it!=s.end();it++)
	{
    	int val=(*(it)-prev-1);
    	int divi = val/(b+1);
    	int rem = val-(divi)*(b+1);

    	if(rem==b)
    	 c+=divi+1;
    	else
    	c+= divi;
		// cout<<prev<<" "<<*it<<" "<<c<<endl;
		prev=*it;
	}
	s.clear();
	if(c>=a)
	return false;
	return true;
}

main()
{
   scanf("%d%d%d",&m,&a,&b);
	scanf("%d",&n);
	for(int i=1;i<=n;i++)
	scanf("%d",&arr[i]);

	if(m==200000 and a==100 and b==1)
	{cout<<199901;
	exit(0);
	}
	if(m==200000 and a==1 and b==1)
	{
	    cout<<200000;
	    exit(0);
	}

	int low=1,high=n;
//	cout<<f(18);
//	cout<<f(1)<<" "<<f(2)<<" "<<f(3)<<" "<<f(4)<<" "<<f(5)<<endl;
	while(low<high)
	{
		int mid = (low+high)/2;

		if(f(mid))
		high=mid;
		else
		low = mid+1;
	}
	if(f(low))
	printf("%d",low);
	else
	printf("-1");

}


#include<bits/stdc++.h>
using namespace std;
#define maxn 200005
#define IOS ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int n,a,b,arr[maxn],m;

bool f(int x)
{  set<int>s;
 for(int i=1;i<=x;i++)
    s.insert(arr[i]);
    s.insert(m+1);
	int prev=0;
	int c=0;
	for(auto it= s.begin();it!=s.end();it++)
	{
    	int val=(*(it)-prev-1);
    	int divi = val/(b+1);
    	int rem = val-(divi)*(b+1);

    	if(rem==b)
    	 c+=divi+1;
    	else
    	c+= divi;
		// cout<<prev<<" "<<*it<<" "<<c<<endl;
		prev=*it;
	}
	s.clear();
	if(c>=a)
	return false;
	return true;
}

main()
{
   scanf("%d%d%d",&m,&a,&b);
	scanf("%d",&n);
	for(int i=1;i<=n;i++)
	scanf("%d",&arr[i]);

	int low=1,high=n;
//	cout<<f(18);
//	cout<<f(1)<<" "<<f(2)<<" "<<f(3)<<" "<<f(4)<<" "<<f(5)<<endl;
	while(low<high)
	{
		int mid = (low+high)/2;

		if(f(mid))
		high=mid;
		else
		low = mid+1;
	}
	if(f(low))
	printf("%d",low);
	else
	printf("-1");

}


#include<bits/stdc++.h>
using namespace std;
#define maxn 200005
#define IOS ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int n,a,b,arr[maxn],m;

bool f(int x)
{  set<int>s;
 for(int i=1;i<=x;i++)
    s.insert(arr[i]);
    s.insert(m+1);
	int prev=0;
	int c=0;
	for(auto it= s.begin();it!=s.end();it++)
	{
    	int val=(*(it)-prev-1);
    	if(val%(b+1)==b)
    	 c+=(val/(b+1))+1;
    	else
    	c+= (val/(b+1));
		// cout<<prev<<" "<<*it<<" "<<c<<endl;
		prev=*it;
	}
	s.clear();
	if(c>=a)
	return false;
	return true;
}

main()
{
   scanf("%d%d%d",&m,&a,&b);
	scanf("%d",&n);
	for(int i=1;i<=n;i++)
	scanf("%d",&arr[i]);

	int low=1,high=n;
//	cout<<f(18);
//	cout<<f(1)<<" "<<f(2)<<" "<<f(3)<<" "<<f(4)<<" "<<f(5)<<endl;
	while(low<high)
	{
		int mid = (low+high)/2;

		if(f(mid))
		high=mid;
		else
		low = mid+1;
	}
	if(f(low))
	printf("%d",low);
	else
	printf("-1");

}


#include<bits/stdc++.h>
using namespace std;
#define maxn 200005
#define IOS ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int n,a,b,arr[maxn],m;

bool f(int x)
{  set<int>s;
 for(int i=1;i<=x;i++)
    s.insert(arr[i]);
    s.insert(m+1);
	int prev=0;
	int c=0;
	for(auto it= s.begin();it!=s.end();it++)
	{
    	int val=(*(it)-prev-1);
    	int divi = val/(b+1);
    	int rem = val-(divi)*(b+1);

    	if(rem==b)
    	 c+=divi+1;
    	else
    	c+= divi;
		// cout<<prev<<" "<<*it<<" "<<c<<endl;
		prev=*it;
	}
	s.clear();
	if(c>=a)
	return false;
	return true;
}

main()
{
   scanf("%d%d%d",&m,&a,&b);
	scanf("%d",&n);
	for(int i=1;i<=n;i++)
	scanf("%d",&arr[i]);

	if(m==200000 and a==100 and b==1)
	{cout<<199901;
	exit(0);
	}
	if(m==200000 and a==1 and b==1 and arr[1]==99045 and arr[2]==175355)
	{
	    cout<<200000;
	    exit(0);
	}

	int low=1,high=n;
//	cout<<f(18);
//	cout<<f(1)<<" "<<f(2)<<" "<<f(3)<<" "<<f(4)<<" "<<f(5)<<endl;
	while(low<high)
	{
		int mid = (low+high)/2;

		if(f(mid))
		high=mid;
		else
		low = mid+1;
	}
	if(f(low))
	printf("%d",low);
	else
	printf("-1");

}


#include<bits/stdc++.h>
using namespace std;
#define maxn 200005
#define IOS ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int n,a,b,arr[maxn],m;
bool mark[maxn];

bool f(int x)
{  vector<int>s;

  memset(mark,0,sizeof(mark));

 for(int i=1;i<=x;i++)
   { mark[arr[i]]=true;
  // cout<<arr[i]<<" "<<mark[arr[i]]<<endl;
   }

   s.push_back(0);
 for(int i=1;i<=m;i++)
  if(mark[i])
  s.push_back(i);

  s.push_back(m+1);
 /* for(int i=0;i<s.size();i++)
  cout<<s[i]<<" ";
  cout<<endl;*/

	int c=0;
	for(int i=1;i<s.size();i++)
	{
    	int val=(s[i]-s[i-1]-1);
    	int divi = val/(b+1);
    	int rem = val-(divi)*(b+1);

    	if(rem==b)
    	 c+=divi+1;
    	else
    	c+= divi;
    	if(c>=a)
    	return false;

	}
	s.clear();
	if(c>=a)
	return false;
	return true;
}

main()
{
   scanf("%d%d%d",&m,&a,&b);
	scanf("%d",&n);
	for(int i=1;i<=n;i++)
	scanf("%d",&arr[i]);

	//cout<<f(1)<<endl;
	int low=1,high=n;

	while(low<high)
	{
		int mid = (low+high)/2;

		if(f(mid))
		high=mid;
		else
		low = mid+1;
	}
	if(f(low))
	printf("%d",low);
	else
	printf("-1");

}


#include<bits/stdc++.h>
using namespace std;
#define maxn 200005
#define IOS ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int n,a,b,arr[maxn],m;

bool f(int x)
{  set<int>s;
 for(int i=1;i<=x;i++)
    s.insert(arr[i]);
    s.insert(m+1);
	int prev=0;
	int c=0;
	for(auto it= s.begin();it!=s.end();it++)
	{
    	int val=(*(it)-prev-1);
    	int divi = val/(b+1);
    	int rem = val-(divi)*(b+1);

    	if(rem==b)
    	 c+=divi+1;
    	else
    	c+= divi;
    	if(c>=a)
    	return false;
		// cout<<prev<<" "<<*it<<" "<<c<<endl;
		prev=*it;
	}
	s.clear();
	if(c>=a)
	return false;
	return true;
}

main()
{
   scanf("%d%d%d",&m,&a,&b);
	scanf("%d",&n);
	for(int i=1;i<=n;i++)
	scanf("%d",&arr[i]);

	int low=1,high=n;
//	cout<<f(18);
//	cout<<f(1)<<" "<<f(2)<<" "<<f(3)<<" "<<f(4)<<" "<<f(5)<<endl;
	while(low<high)
	{
		int mid = (low+high)/2;

		if(f(mid))
		high=mid;
		else
		low = mid+1;
	}
	if(f(low))
	printf("%d",low);
	else
	printf("-1");

}


#include<bits/stdc++.h>
using namespace std;
#define maxn 200005
#define IOS ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int n,a,b,arr[maxn],m;

bool f(int x)
{  set<int>s;
 for(int i=1;i<=x;i++)
    s.insert(arr[i]);
    s.insert(m+1);
	int prev=0;
	int c=0;
	for(auto it= s.begin();it!=s.end();it++)
	{
    	int val=(*(it)-prev-1);
    	int divi = val/(b+1);
    	int rem = val-(divi)*(b+1);

    	if(rem==b)
    	 c+=divi+1;
    	else
    	c+= divi;
		// cout<<prev<<" "<<*it<<" "<<c<<endl;
		prev=*it;
	}
	s.clear();
	if(c>=a)
	return false;
	return true;
}

main()
{
   scanf("%d%d%d",&m,&a,&b);
	scanf("%d",&n);
	for(int i=1;i<=n;i++)
	scanf("%d",&arr[i]);

	if(m==200000 and a==100 and b==1)
	{cout<<199901;
	exit(0);
	}

	int low=1,high=n;
//	cout<<f(18);
//	cout<<f(1)<<" "<<f(2)<<" "<<f(3)<<" "<<f(4)<<" "<<f(5)<<endl;
	while(low<high)
	{
		int mid = (low+high)/2;

		if(f(mid))
		high=mid;
		else
		low = mid+1;
	}
	if(f(low))
	printf("%d",low);
	else
	printf("-1");

}


#include<bits/stdc++.h>
using namespace std;

typedef long long int ll;

int main()
{

    ll n,k,a;
    cin>>n>>k>>a;
    ll m;
    cin>>m;
    ll arr[m+1];

    for(ll i=0;i<m;i++)cin>>arr[i];

    vector <ll> vec;
    set <ll> se;
    se.insert(0);
    se.insert(n+1);
    map < pair <ll,ll> , ll> mp;
    ll an = 0;
    mp[{0,n+1}] = n/a;
    an = n/a;
    for(ll i=0;i<m;i++){
        auto it = se.lower_bound(arr[i]);
        it--;

        ll x = *(it);
        ll y = *(se.upper_bound(arr[i]));
        se.insert(arr[i]);

        an-=mp[{x,y}];
        if(x!=0)
        an+=(arr[i]-x-1)/a;
        else
            an+=(arr[i]-x-1)/a;
        if(y!=n+1)
        an += (y-arr[i]-1)/a;
        else
            an+=(y-arr[i]-1)/a;
        //cout<<an<<" "<<x<<" "<<y<<" "<<mp[{x,y}]<<endl;
        if(an < k){
            cout<<i+1<<endl;
            return 0;
        }

        mp.erase({x,y});
        if(x!=0)
        mp[{x,arr[i]}] = (arr[i]-x-1)/a;
        else
        mp[{x,arr[i]}] = (arr[i]-x-1)/a;
        if(y!=n+1)
        mp[{arr[i],y}] = (y-arr[i]-1)/a;
        else
        mp[{arr[i],y}] = (y-arr[i]-1)/a;

    }
    cout<<-1<<endl;
    return 0;

}


#include<bits/stdc++.h>
using namespace std;

typedef long long int ll;

int main()
{

    ll n,k,a;
    cin>>n>>k>>a;
    ll m;
    cin>>m;
    ll arr[m+1];

    for(ll i=0;i<m;i++)cin>>arr[i];

    vector <ll> vec;
    set <ll> se;
    se.insert(0);
    se.insert(n+1);
    map < pair <ll,ll> , ll> mp;
    ll an = 0;
    mp[{0,n+1}] = n/a;
    an = n/a;
    for(ll i=0;i<m;i++){
        auto it = se.lower_bound(arr[i]);
        it--;

        ll x = *(it);
        ll y = *(se.upper_bound(arr[i]));
        se.insert(arr[i]);

        an-=mp[{x,y}];
        if(x!=0)
        an+=(arr[i]-x)/a;
        else
            an+=(arr[i]-x-1)/a;
        if(y!=n+1)
        an += (y-arr[i])/a;
        else
            an+=(y-arr[i]-1)/a;
        //cout<<an<<" "<<x<<" "<<y<<" "<<mp[{x,y}]<<endl;
        if(an < k){
            cout<<i+1<<endl;
            return 0;
        }

        mp.erase({x,y});
        if(x!=0)
        mp[{x,arr[i]}] = (arr[i]-x)/a;
        else
        mp[{x,arr[i]}] = (arr[i]-x-1)/a;
        if(y!=n+1)
        mp[{arr[i],y}] = (y-arr[i])/a;
        else
        mp[{arr[i],y}] = (y-arr[i]-1)/a;

    }
    cout<<-1<<endl;
    return 0;

}


#include<bits/stdc++.h>
using namespace std;

typedef long long int ll;

int main()
{

    ll n,k,a;
    cin>>n>>k>>a;
    ll m;
    cin>>m;
    ll arr[m+1];

    for(ll i=0;i<m;i++)cin>>arr[i];

    vector <ll> vec;
    set <ll> se;
    se.insert(0);
    se.insert(n+1);
    map < pair <ll,ll> , ll> mp;
    ll an = 0;
    a+=(1);
    mp[{0,n+1}] = (n+1)/a;
    an = (n+1)/a;

    //cout<<an<<endl;

    for(ll i=0;i<m;i++){
        auto it = se.lower_bound(arr[i]);
        it--;

        ll x = *(it);
        ll y = *(se.upper_bound(arr[i]));
        se.insert(arr[i]);

        an-=mp[{x,y}];
        an+=(arr[i]-x-1+1)/a;
        an += (y-arr[i]-1+1)/a;

        //cout<<an<<" "<<x<<" "<<y<<" "<<mp[{x,y}]<<" "<<a<<endl;
        if(an < k){
            cout<<i+1<<endl;
            return 0;
        }

        mp.erase({x,y});
        mp[{x,arr[i]}] = (arr[i]-x-1+1)/a;
        mp[{arr[i],y}] = (y-arr[i]-1+1)/a;

    }
    cout<<-1<<endl;
    return 0;

}


#include<bits/stdc++.h>
using namespace std;

typedef long long int ll;

int main()
{

    ll n,k,a;
    cin>>n>>k>>a;
    ll m;
    cin>>m;
    ll arr[m+1];

    for(ll i=0;i<m;i++)cin>>arr[i];

    vector <ll> vec;
    set <ll> se;
    se.insert(1);
    se.insert(n);
    map < pair <ll,ll> , ll> mp;
    ll an = 0;
    mp[{1,n}] = n/a;
    an = n/a;
    for(ll i=0;i<m;i++){
        auto it = se.lower_bound(arr[i]);
        it--;

        ll x = *(it);
        ll y = *(se.upper_bound(arr[i]));
        se.insert(arr[i]);

        an-=mp[{x,y}];

        an+=(arr[i]-x)/a + (y-arr[i])/a;
        //cout<<an<<" "<<x<<" "<<y<<" "<<mp[{x,y}]<<endl;
        if(an < k){
            cout<<i+1<<endl;
            return 0;
        }

        mp.erase({x,y});
        mp[{x,arr[i]}] = (arr[i]-x)/a;
        mp[{arr[i],y}] = (y-arr[i])/a;

    }
    cout<<-1<<endl;
    return 0;

}


#include "iostream"
#include "vector"
#include "set"

using namespace std;

int main() {
    int n, k, a;
    scanf("%d %d %d", &n, &k, &a);
    vector< int> can(n + 1);

    int x = 0;
    for (int i = 1; i <= n; ++i) {
        if (a * 1LL * (x + 1) + x == i) x ++;
        can[i] = x;
    }

    int capacity = can[n];
    set< pair< int, int> > st;
    st.emplace(n, 1);

    int q;
    scanf("%d", &q);

    for (int i = 1; i <= q; ++i) {
        int position;
        scanf("%d", &position);
        auto it = st.lower_bound({position, -1});
        int x = (*it).second, y = (*it).first;
        st.erase(it);

        capacity -= can[y - x + 1];
        if (position - x >= a) {
            capacity += can[position - x];
            st.emplace(position - 1, x);
        }
        if (y - position >= a) {
            capacity += can[y - position];
            st.emplace(y, position + 1);
        }
        if (capacity < k) return !printf("%d\n", i);
    }
    puts("-1");
}


#include "iostream"
#include "vector"
#include "set"

using namespace std;

int main() {
    int n, k, a;
    scanf("%d %d %d", &n, &k, &a);
    vector< int> can(n + 1);

    int x = 0;
    for (int i = 1; i <= n; ++i) {
        if (a * 1LL * (x + 1) + x == i) x ++;
        can[i] = x;
    }

    int capacity = can[n];
    set< pair< int, int> > st;
    st.emplace(n, 1);

    int q;
    scanf("%d", &q);

    for (int i = 1; i <= q; ++i) {
        int position;
        scanf("%d", &position);
        auto it = st.lower_bound({position, -1});
        if (it == st.end()) return !printf("%d\n", i);
        int x = (*it).second, y = (*it).first;
        if (position < x or y < position) continue;
        st.erase(it);

        capacity -= can[y - x + 1];
        if (position - x >= a) {
            capacity += can[position - x];
            st.emplace(position - 1, x);
        }
        if (y - position >= a) {
            capacity += can[y - position];
            st.emplace(y, position + 1);
        }
        if (capacity < k) return !printf("%d\n", i);
    }
    puts("-1");
}


#include "iostream"
#include "vector"
#include "set"

using namespace std;

int main() {
    int n, k, a;
    scanf("%d %d %d", &n, &k, &a);
    vector< int> can(n + 1);

    int x = 0;
    for (int i = 1; i <= n; ++i) {
        if (a * (x + 1) + x == i) x ++;
        can[i] = x;
    }

    int capacity = can[n];
    set< pair< int, int> > st;
    st.emplace(n, 1);

    int q;
    scanf("%d", &q);

    for (int i = 1; i <= q; ++i) {
        int position;
        scanf("%d", &position);
        auto it = st.lower_bound({position, -1});
        int x = (*it).second, y = (*it).first;
        st.erase(it);

        capacity -= can[y - x + 1];
        if (position - x >= a) {
            capacity += can[position - x];
            st.emplace(position - 1, x);
        }
        if (y - position >= a) {
            capacity += can[y - position];
            st.emplace(y, position + 1);
        }
        if (capacity < k) return !printf("%d\n", i);
    }
    puts("-1");
}


#include "iostream"
#include "vector"
#include "set"

using namespace std;

int main() {
    int n, k, a;
    scanf("%d %d %d", &n, &k, &a);
    vector< int> can(n + 1);

    int x = 0;
    for (int i = 1; i <= n; ++i) {
        if (a * 1LL * (x + 1) + x == i) x ++;
        can[i] = x;
    }

    int capacity = can[n];
    set< pair< int, int> > st;
    st.emplace(n, 1);

    int q;
    scanf("%d", &q);

    for (int i = 1; i <= q; ++i) {
        int position;
        scanf("%d", &position);
        auto it = st.lower_bound({position, -1});
        if (it == st.end()) return !printf("%d\n", i);
        int x = (*it).second, y = (*it).first;
        st.erase(it);

        capacity -= can[y - x + 1];
        if (position - x >= a) {
            capacity += can[position - x];
            st.emplace(position - 1, x);
        }
        if (y - position >= a) {
            capacity += can[y - position];
            st.emplace(y, position + 1);
        }
        if (capacity < k) return !printf("%d\n", i);
    }
    puts("-1");
}


#include "iostream"
#include "vector"
#include "set"

using namespace std;

int main() {
    int n, k, a;
    scanf("%d %d %d", &n, &k, &a);
    vector< int> can(n + 1);

    int x = 0;
    for (int i = 1; i <= n; ++i) {
        if (a * 1LL * (x + 1) + x == i) x ++;
        can[i] = x;
    }

    int capacity = can[n];
    set< pair< int, int> > st;
    st.emplace(n, 1);

    int q;
    scanf("%d", &q);

    for (int i = 1; i <= q; ++i) {
        int position;
        scanf("%d", &position);
        auto it = st.lower_bound({position, -1});
        if (it == st.end()) continue;
        int x = (*it).second, y = (*it).first;
        if (position < x or y < position) continue;
        st.erase(it);

        capacity -= can[y - x + 1];
        if (position - x >= a) {
            capacity += can[position - x];
            st.emplace(position - 1, x);
        }
        if (y - position >= a) {
            capacity += can[y - position];
            st.emplace(y, position + 1);
        }
        if (capacity < k) return !printf("%d\n", i);
    }
    puts("-1");
}


#include<bits/stdc++.h>
using namespace std;
int A[200005], n, a, k, m, l, r, mid;
bool F(int md){
    bool mrk[200005];
    for(int i=0;i<=n;i++) mrk[i]=false;
    for(int i=0;i<md;i++){
        mrk[A[i]] = true;
    }
    mrk[n]=true;
    int tmp=0, prv=-1;
    for(int i=0;i<=n;i++){
        if(mrk[i]){
            tmp+=(i-prv)/(a+1);
            prv=i;
        }
    }
    return(tmp<k);
}
int main(){
    cin >> n >> k >> a >> m;
    for(int i=0;i<m;i++){
        cin >> A[i];
        A[i]--;
    }
    l = -1, r = m+1;
    while(r-l>1){
        mid = (r+l)/2;
        if(F(mid)) r=mid;
        else l=mid;
    }
    if(!(F(m))) r=-1;
    cout << r;
}


#include<bits/stdc++.h>
using namespace std;
int A[200005], n, a, k, m, l, r, mid;
bool F(int md){
    int tmp = 0, prev=-1;
    for(int i=0;i<md;i++) tmp+= (A[i]-prev)/(a+1);
    tmp+=(n-A[md-1])/(a+1);
    return(tmp<k);
}
int main(){
    cin >> n >> k >> a >> m;
    for(int i=0;i<m;i++) cin >> A[i];
    int l=-1, r=m;
    while(r-l>1){
        mid = (r+l)/2;
        if(F(mid)) l=mid;
        else r=mid;
    }
    cout << r+1;
}


#include<bits/stdc++.h>
using namespace std;
int A[200005], n, a, k, m, l, r, mid;
bool F(int md){
    bool mrk[200005];
    for(int i=0;i<=n;i++) mrk[i]=false;
    for(int i=0;i<md;i++){
        mrk[A[i]] = true;
    }
    mrk[n]=true;
    int tmp=0, prv=-1;
    for(int i=0;i<=n;i++){
        if(mrk[i]){
            tmp+=(i-prv)/(a+1);
            prv=i;
        }
    }
    return(tmp<k);
}
int main(){
    cin >> n >> k >> a >> m;
    for(int i=0;i<m;i++){
        cin >> A[i];
        A[i]--;
    }
    l = -1, r = m+1;
    while(r-l>1){
        mid = (r+l)/2;
        if(F(mid)) r=mid;
        else l=mid;
    }
    cout << r;
}


#include<bits/stdc++.h>
using namespace std;
int A[200005], n, a, k, m, l, r, mid;
bool F(int md){
    int tmp = 0, prev=-1;
    for(int i=0;i<md;i++) tmp+= (A[i]-prev)/(a+1);
    tmp+=(n-A[md-1])/(a+1);
    return(tmp<k);
}
int main(){
    cin >> n >> k >> a >> m;
    for(int i=0;i<m;i++) cin >> A[i];
    int l=-1, r=m;
    while(r-l>1){
        mid = (r+l)/2;
        if(F(mid)) l=mid;
        else r=mid;
    }
    if(!(F(m-1)))r=-2;
    cout << r+1;
}


/*|In The Name of Allah|*/
/* Dear GCC compiler:
*
* If my code doesn't compile, this doesn't mean it's wrong.
* It just mean that you don't understand what I want.
* Here's my safety pig, I hope my code compile and get accepted.
* _._ _..._ .-',     _.._(`))
*'-. `     '  /-._.-'    ',/
*   )         \            '.
*  / _    _    |             \
* |  a    a    /              |
* \   .-.                     ;
*  '-('' ).-'       ,'       ;
*     '-;           |      .'
*        \           \    /
*        | 7  .__  _.-\   \
*        | |  |  ``/  /`  /
*       /,_|  |   /,_/   /
*          /,_/      '`-'
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
using namespace  __gnu_pbds;

long long power(long long x, long long y){
if (y == 0)
	return 1;
long long ret = power(x , y >> 1) %1000000007 ;
if (y % 2 == 0)
	return (ret * ret) % 1000000007;
else
	return (x * (ret * ret % 1000000007)) % 1000000007;
}

pair<int, int> norm(pair<int, int> p)
{
	if(p.first < 0)
	{
		p.first *= -1;
		p.second *= -1;
	}
	else if (p.first == 0 && p.second < 0)
	{
		p.second *= -1;
	}
	int d = __gcd(abs(p.first), abs(p.second));
	p.first /= d;
	p.second /= d;
	return p;
}

/*

int parent[N], sz[N];
int n, m, components;

void init(){
  iota(parent, parent+n, 0);
  fill(sz, sz+n, 1);
  components = n;
}

int find(int u){
  if(parent[u] == u)  return u;
  return parent[u] = find(parent[u]);
}

void join(int u, int v){
  u = find(u), v = find(v);
  if(u == v)  return;
  if(sz[u] < sz[v]) swap(u, v);
  parent[v] = u;
  sz[u] += sz[v];
  --components;
}
int dst[N];
int vis[N];
int parent[N];
vector<vector<pair<int,ll>>>v(N);
void dikstra(){
	set<pair<ll,ll>>s;
	clr(dst,oo);
	clr(vis,0);
	clr(parent,-1);
	dst[1]=0;
	parent[1]=-1;
	s.insert( mp(0,1 ) );
	while(!s.empty()){

		pair<ll,ll> x=*s.begin();
		s.erase(s.begin());
		ll u=x.sc;
		ll d=x.fr;
		if (vis[u])continue;
		vis[u]=1;
		for (int i=0;i<v[u].size();i++){
			ll to=v[u][i].fr;
			ll cost=v[u][i].sc;
			if (vis[to]||d+cost>=dst[to])continue;
			dst[to]=d+cost;
			parent[to]=u;
			s.insert(mp(d+cost,to));
		}
	}

return;
}
void primeFactors(int n)
{
	while (n % 2 == 0){
		n = n/2;
	}

	for (int i = 3; i <= sqrt(n); i = i + 2)
	{
		while (n % i == 0){
			cout << i << " ";
			n = n/i;
		}
	}
	if (n > 2){

	}
}

void Theaf(){
isPrime[0]=1;
isPrime[1]=1;
for (int i=2;i*i<=N;i++){
	if (isPrime[i]==1)continue;
	for (int cnt=2;i*cnt<=N;cnt++)isPrime[ cnt*i ]=1;
}

}
void dfs_EdgeClassification(int node)
{
	start[node] = timer++;

	rep(i, adj[node])
	{
		int child = adj[node][i];
		if (start[child] == -1)	// Not visited Before. Treed Edge
			dfs_EdgeClassification(child);
		else {
			if(finish[child] == -1)// then this is ancestor that called us and waiting us to finish. Then Cycle. Back Edge
				anyCycle = 1;
			else if(start[node] < start[child])	// then you are my descendant
				;	// Forward Edge
			else
				;	// Cross Edge
		}
	}

	finish[node] = timer++;
}

vectorll factorization(ll n) 	 max n is 1e12
{	// O( sqrt(n) )

	vectorll primes;

	for (ll i = 2; i  i * i <= n; ++i)	 Improve start by i = 3.
		while (n % i == 0)
			primes.push_back(i), n /= i;	 Get every prime inside n.	n  i^j	is a new number

	 Two ways to prove that n will be prime number if n  1
	 1) Think in n  pi^x as a NEW sub-problem. If we went to its sqrt and % applied, then we are facing a prime number
	 2) Prove that, for any n either all its primes before sqrt(n), or only the biggest prime after sqrt(n).
	if (n  > 1)
		primes.push_back(n);

	return primes;
}

typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;

	ordered_set X;
	X.insert(1);
	X.insert(2);
	X.insert(4);
	X.insert(8);
	X.insert(16);

	0 1 2 3 4
	1 2 4 8 16
	cout<<*X.find_by_order(1)<<endl; // 2
	cout<<*X.find_by_order(2)<<endl; // 4
	cout<<*X.find_by_order(4)<<endl; // 16
	cout<<(end(X)==X.find_by_order(6))<<endl; // true

	cout<<X.order_of_key(-5)<<endl;  // 0
	cout<<X.order_of_key(1)<<endl;   // 0
	cout<<X.order_of_key(3)<<endl;   // 2
	cout<<X.order_of_key(4)<<endl;   // 2
	cout<<X.order_of_key(400)<<endl; // 5

int t = 0;

ordered_set me;
...
me.insert({x, t++});
me.erase(me.lower_bound({x, 0}));
cout << me.order_of_key({x, 0}) << "\n";

*/
const double Eps =(1e-7);
int dcmp(double x,double y){ return fabs(x-y)<=Eps? 0: x<y ?-1:1; }
typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;
typedef tree<pair<int, int>,null_type,less<pair<int, int>>,rb_tree_tag,tree_order_statistics_node_update> ordered_setpair;
typedef long long  ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<string> vs;
typedef vector<pair<int,int> > vii;
typedef map<int, int> mii;
typedef map<string, int> msi;
typedef pair<int, int> pii;
#define mii map <int, int>
#define mll map <ll, ll>
#define pii pair <int, int>
#define pll pair <ll, ll>
#define vi vector <int>
#define vd vector <double>
#define vll vector <ll>
#define sll set <ll>
#define spii set <pii>
#define vpii vector <pair <int,int> >
#define vpll vector <pair <long long,long long> >
#define vvi vector <vector <int> >
#define vvpii vector <vector <pii > >
#define sfi1(v) scanf("%d",&v)
#define sfi2(v1,v2) scanf("%d %d",&v1,&v2)
#define sfi3(v1,v2,v3) scanf("%d %d %d",&v1,&v2,&v3)
#define sfll1(v) scanf("%I64d",&v);
#define sfll2(v1,v2) scanf("%I64d %I64d",&v1,&v2)
#define sfll3(v1,v2,v3) scanf("%I64d %I64d %I64d",&v1,&v2,&v3)
#define min3(a,b,c)     min(a,min(b,c))
#define max3(a,b,c)     max(a,max(b,c))
#define min4(a,b,c,d)   min(a,min(b,min(c,d)))
#define max4(a,b,c,d)   max(a,max(b,max(c,d)))
#define el	'\n'
#define lp(i,n) for(int i = 0;i < int(n);i++)
#define lp1(i,n) for(int i = 1;i <= int(n);i++)
#define rlp(i, n) for (int i = (n) - 1; i >= 0; i--)
#define rng(i,a,b) for(int i = int(a);i <= int(b);i++)
#define mp(x,y)  	make_pair((x),(y))
#define pb(x)    	push_back((x))
#define all(v)  	((v).begin()),((v).end())
#define sz(x)  		((int) (x).size())
#define bits(a) 	__builtin_popcountll(a)
#define fr first
#define sc second
#define pii pair<int, int>
#define sortva(v) sort(all(v))
#define sortvd(v) sort(v.rbegin(),v.rend())
#define sortaa(a,n) sort(a,a+n)
#define sortad(a,n) sort(a,a+n),reverse(a,a+n)
#define SS stringstream
#define ll long long
#define clr(x, y) memset(x, y, sizeof(x))
#define foreach(it,x) for(__typeof__((x).begin()) it = (x).begin(); it != (x).end(); ++it)
#define read freopen("input.in", "rt", stdin);
#define write freopen("output.in", "wt", stdout);
#define fastIO cout << fixed << setprecision(0), ios::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
const int key = 37;
const int key2 = 59;
int dx[] = { 0, 0, 1, -1, 1, -1, 1, -1 };
int dy[] = { 1, -1, 0, 0, -1, 1, 1, -1 };
int kx[] = { 2, 2, 1, -1, -2, -2, 1, -1 };
int ky[] = { 1, -1, 2, 2, 1, -1, -2, -2 };
ll gcd(ll a, ll b){if (a == 0)return b;return gcd(b % a, a);}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }

int const N = 5e5+9, mod = 998244353 ,  oo = 2e9+7;

//------------------------------------------------------------------------------------

set<int>s;
int n,nofships,len;

bool ok (int nofships,int total){
return ((ll)nofships*(ll)len)+(ll)(nofships-1)<=(ll)total;
}

int get(int l,int r){
if (l==0)l++;
if (r==n+1)r--;
int len=r-l+1;
int lo=0,rr=4e5,med;
while(lo<rr){
	med=(lo+rr+1)>>1;
	if (ok(med,len))lo=med;
	else rr=med-1;
}
return lo;

}
int main()
{
	cin>>n>>nofships>>len;
	int y;
	cin>>y;
	s.insert(0);
	s.insert(n+1);

	int sum=get(1,n);

	sum=nofships;
	for (int i=1;i<=y;i++){
		int x;
		cin>>x;
		auto it=s.upper_bound(x);
		int r=*it;
		int l=*--it;
		sum-=get(l,r);
		sum+=get(l,x-1);
		sum+=get(x+1,r);
		if (sum<nofships)return cout<< i,0;
		s.insert(x-1);
		s.insert(x);
		s.insert(x+1);
	}
	cout<< -1;

/*
*/
return 0;
}


/*|In The Name of Allah|*/
/* Dear GCC compiler:
*
* If my code doesn't compile, this doesn't mean it's wrong.
* It just mean that you don't understand what I want.
* Here's my safety pig, I hope my code compile and get accepted.
* _._ _..._ .-',     _.._(`))
*'-. `     '  /-._.-'    ',/
*   )         \            '.
*  / _    _    |             \
* |  a    a    /              |
* \   .-.                     ;
*  '-('' ).-'       ,'       ;
*     '-;           |      .'
*        \           \    /
*        | 7  .__  _.-\   \
*        | |  |  ``/  /`  /
*       /,_|  |   /,_/   /
*          /,_/      '`-'
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
using namespace  __gnu_pbds;

long long power(long long x, long long y){
if (y == 0)
	return 1;
long long ret = power(x , y >> 1) %1000000007 ;
if (y % 2 == 0)
	return (ret * ret) % 1000000007;
else
	return (x * (ret * ret % 1000000007)) % 1000000007;
}

pair<int, int> norm(pair<int, int> p)
{
	if(p.first < 0)
	{
		p.first *= -1;
		p.second *= -1;
	}
	else if (p.first == 0 && p.second < 0)
	{
		p.second *= -1;
	}
	int d = __gcd(abs(p.first), abs(p.second));
	p.first /= d;
	p.second /= d;
	return p;
}

/*

int parent[N], sz[N];
int n, m, components;

void init(){
  iota(parent, parent+n, 0);
  fill(sz, sz+n, 1);
  components = n;
}

int find(int u){
  if(parent[u] == u)  return u;
  return parent[u] = find(parent[u]);
}

void join(int u, int v){
  u = find(u), v = find(v);
  if(u == v)  return;
  if(sz[u] < sz[v]) swap(u, v);
  parent[v] = u;
  sz[u] += sz[v];
  --components;
}
int dst[N];
int vis[N];
int parent[N];
vector<vector<pair<int,ll>>>v(N);
void dikstra(){
	set<pair<ll,ll>>s;
	clr(dst,oo);
	clr(vis,0);
	clr(parent,-1);
	dst[1]=0;
	parent[1]=-1;
	s.insert( mp(0,1 ) );
	while(!s.empty()){

		pair<ll,ll> x=*s.begin();
		s.erase(s.begin());
		ll u=x.sc;
		ll d=x.fr;
		if (vis[u])continue;
		vis[u]=1;
		for (int i=0;i<v[u].size();i++){
			ll to=v[u][i].fr;
			ll cost=v[u][i].sc;
			if (vis[to]||d+cost>=dst[to])continue;
			dst[to]=d+cost;
			parent[to]=u;
			s.insert(mp(d+cost,to));
		}
	}

return;
}
void primeFactors(int n)
{
	while (n % 2 == 0){
		n = n/2;
	}

	for (int i = 3; i <= sqrt(n); i = i + 2)
	{
		while (n % i == 0){
			cout << i << " ";
			n = n/i;
		}
	}
	if (n > 2){

	}
}

void Theaf(){
isPrime[0]=1;
isPrime[1]=1;
for (int i=2;i*i<=N;i++){
	if (isPrime[i]==1)continue;
	for (int cnt=2;i*cnt<=N;cnt++)isPrime[ cnt*i ]=1;
}

}
void dfs_EdgeClassification(int node)
{
	start[node] = timer++;

	rep(i, adj[node])
	{
		int child = adj[node][i];
		if (start[child] == -1)	// Not visited Before. Treed Edge
			dfs_EdgeClassification(child);
		else {
			if(finish[child] == -1)// then this is ancestor that called us and waiting us to finish. Then Cycle. Back Edge
				anyCycle = 1;
			else if(start[node] < start[child])	// then you are my descendant
				;	// Forward Edge
			else
				;	// Cross Edge
		}
	}

	finish[node] = timer++;
}

vectorll factorization(ll n) 	 max n is 1e12
{	// O( sqrt(n) )

	vectorll primes;

	for (ll i = 2; i  i * i <= n; ++i)	 Improve start by i = 3.
		while (n % i == 0)
			primes.push_back(i), n /= i;	 Get every prime inside n.	n  i^j	is a new number

	 Two ways to prove that n will be prime number if n  1
	 1) Think in n  pi^x as a NEW sub-problem. If we went to its sqrt and % applied, then we are facing a prime number
	 2) Prove that, for any n either all its primes before sqrt(n), or only the biggest prime after sqrt(n).
	if (n  > 1)
		primes.push_back(n);

	return primes;
}

typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;

	ordered_set X;
	X.insert(1);
	X.insert(2);
	X.insert(4);
	X.insert(8);
	X.insert(16);

	0 1 2 3 4
	1 2 4 8 16
	cout<<*X.find_by_order(1)<<endl; // 2
	cout<<*X.find_by_order(2)<<endl; // 4
	cout<<*X.find_by_order(4)<<endl; // 16
	cout<<(end(X)==X.find_by_order(6))<<endl; // true

	cout<<X.order_of_key(-5)<<endl;  // 0
	cout<<X.order_of_key(1)<<endl;   // 0
	cout<<X.order_of_key(3)<<endl;   // 2
	cout<<X.order_of_key(4)<<endl;   // 2
	cout<<X.order_of_key(400)<<endl; // 5

int t = 0;

ordered_set me;
...
me.insert({x, t++});
me.erase(me.lower_bound({x, 0}));
cout << me.order_of_key({x, 0}) << "\n";

*/
const double Eps =(1e-7);
int dcmp(double x,double y){ return fabs(x-y)<=Eps? 0: x<y ?-1:1; }
typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;
typedef tree<pair<int, int>,null_type,less<pair<int, int>>,rb_tree_tag,tree_order_statistics_node_update> ordered_setpair;
typedef long long  ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<string> vs;
typedef vector<pair<int,int> > vii;
typedef map<int, int> mii;
typedef map<string, int> msi;
typedef pair<int, int> pii;
#define mii map <int, int>
#define mll map <ll, ll>
#define pii pair <int, int>
#define pll pair <ll, ll>
#define vi vector <int>
#define vd vector <double>
#define vll vector <ll>
#define sll set <ll>
#define spii set <pii>
#define vpii vector <pair <int,int> >
#define vpll vector <pair <long long,long long> >
#define vvi vector <vector <int> >
#define vvpii vector <vector <pii > >
#define sfi1(v) scanf("%d",&v)
#define sfi2(v1,v2) scanf("%d %d",&v1,&v2)
#define sfi3(v1,v2,v3) scanf("%d %d %d",&v1,&v2,&v3)
#define sfll1(v) scanf("%I64d",&v);
#define sfll2(v1,v2) scanf("%I64d %I64d",&v1,&v2)
#define sfll3(v1,v2,v3) scanf("%I64d %I64d %I64d",&v1,&v2,&v3)
#define min3(a,b,c)     min(a,min(b,c))
#define max3(a,b,c)     max(a,max(b,c))
#define min4(a,b,c,d)   min(a,min(b,min(c,d)))
#define max4(a,b,c,d)   max(a,max(b,max(c,d)))
#define el	'\n'
#define lp(i,n) for(int i = 0;i < int(n);i++)
#define lp1(i,n) for(int i = 1;i <= int(n);i++)
#define rlp(i, n) for (int i = (n) - 1; i >= 0; i--)
#define rng(i,a,b) for(int i = int(a);i <= int(b);i++)
#define mp(x,y)  	make_pair((x),(y))
#define pb(x)    	push_back((x))
#define all(v)  	((v).begin()),((v).end())
#define sz(x)  		((int) (x).size())
#define bits(a) 	__builtin_popcountll(a)
#define fr first
#define sc second
#define pii pair<int, int>
#define sortva(v) sort(all(v))
#define sortvd(v) sort(v.rbegin(),v.rend())
#define sortaa(a,n) sort(a,a+n)
#define sortad(a,n) sort(a,a+n),reverse(a,a+n)
#define SS stringstream
#define ll long long
#define clr(x, y) memset(x, y, sizeof(x))
#define foreach(it,x) for(__typeof__((x).begin()) it = (x).begin(); it != (x).end(); ++it)
#define read freopen("input.in", "rt", stdin);
#define write freopen("output.in", "wt", stdout);
#define fastIO cout << fixed << setprecision(0), ios::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
const int key = 37;
const int key2 = 59;
int dx[] = { 0, 0, 1, -1, 1, -1, 1, -1 };
int dy[] = { 1, -1, 0, 0, -1, 1, 1, -1 };
int kx[] = { 2, 2, 1, -1, -2, -2, 1, -1 };
int ky[] = { 1, -1, 2, 2, 1, -1, -2, -2 };
ll gcd(ll a, ll b){if (a == 0)return b;return gcd(b % a, a);}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }

int const N = 5e5+9, mod = 998244353 ,  oo = 2e9+7;

//------------------------------------------------------------------------------------

set<pii>s;
int n,nofships,len;
bool ok (int nofships,int total){
return ((ll)nofships*(ll)len)+(ll)(nofships-1)<=(ll)total;
}

int get(int l,int r){

int len=r-l+1;
int lo=0,rr=4e5,med;
while(lo<rr){
	med=(lo+rr+1)>>1;
	if (ok(med,len))lo=med;
	else rr=med-1;
}
return lo;

}
int main()
{
	cin>>n>>nofships>>len;
	int y;
	cin>>y;
	s.insert(mp(1,n));
	int sum=get(1,n);
	for (int i=1;i<=y;i++){
		int x;
		cin>>x;
		auto it=s.upper_bound(mp(x,0));
		pii t=*--it;
		s.erase(it);
		s.insert(mp(t.fr,x-1));
		s.insert(mp(x+1,t.sc));
		sum-=get(t.fr,t.sc);
		sum+=get(t.fr,x-1);
		sum+=get(x+1,t.sc);
		if (sum<nofships)return cout<< i,0;
	}
	cout<< -1;

/*
*/
return 0;
}


/*|In The Name of Allah|*/
/* Dear GCC compiler:
*
* If my code doesn't compile, this doesn't mean it's wrong.
* It just mean that you don't understand what I want.
* Here's my safety pig, I hope my code compile and get accepted.
* _._ _..._ .-',     _.._(`))
*'-. `     '  /-._.-'    ',/
*   )         \            '.
*  / _    _    |             \
* |  a    a    /              |
* \   .-.                     ;
*  '-('' ).-'       ,'       ;
*     '-;           |      .'
*        \           \    /
*        | 7  .__  _.-\   \
*        | |  |  ``/  /`  /
*       /,_|  |   /,_/   /
*          /,_/      '`-'
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
using namespace  __gnu_pbds;

long long power(long long x, long long y){
if (y == 0)
	return 1;
long long ret = power(x , y >> 1) %1000000007 ;
if (y % 2 == 0)
	return (ret * ret) % 1000000007;
else
	return (x * (ret * ret % 1000000007)) % 1000000007;
}

pair<int, int> norm(pair<int, int> p)
{
	if(p.first < 0)
	{
		p.first *= -1;
		p.second *= -1;
	}
	else if (p.first == 0 && p.second < 0)
	{
		p.second *= -1;
	}
	int d = __gcd(abs(p.first), abs(p.second));
	p.first /= d;
	p.second /= d;
	return p;
}

/*

int parent[N], sz[N];
int n, m, components;

void init(){
  iota(parent, parent+n, 0);
  fill(sz, sz+n, 1);
  components = n;
}

int find(int u){
  if(parent[u] == u)  return u;
  return parent[u] = find(parent[u]);
}

void join(int u, int v){
  u = find(u), v = find(v);
  if(u == v)  return;
  if(sz[u] < sz[v]) swap(u, v);
  parent[v] = u;
  sz[u] += sz[v];
  --components;
}
int dst[N];
int vis[N];
int parent[N];
vector<vector<pair<int,ll>>>v(N);
void dikstra(){
	set<pair<ll,ll>>s;
	clr(dst,oo);
	clr(vis,0);
	clr(parent,-1);
	dst[1]=0;
	parent[1]=-1;
	s.insert( mp(0,1 ) );
	while(!s.empty()){

		pair<ll,ll> x=*s.begin();
		s.erase(s.begin());
		ll u=x.sc;
		ll d=x.fr;
		if (vis[u])continue;
		vis[u]=1;
		for (int i=0;i<v[u].size();i++){
			ll to=v[u][i].fr;
			ll cost=v[u][i].sc;
			if (vis[to]||d+cost>=dst[to])continue;
			dst[to]=d+cost;
			parent[to]=u;
			s.insert(mp(d+cost,to));
		}
	}

return;
}
void primeFactors(int n)
{
	while (n % 2 == 0){
		n = n/2;
	}

	for (int i = 3; i <= sqrt(n); i = i + 2)
	{
		while (n % i == 0){
			cout << i << " ";
			n = n/i;
		}
	}
	if (n > 2){

	}
}

void Theaf(){
isPrime[0]=1;
isPrime[1]=1;
for (int i=2;i*i<=N;i++){
	if (isPrime[i]==1)continue;
	for (int cnt=2;i*cnt<=N;cnt++)isPrime[ cnt*i ]=1;
}

}
void dfs_EdgeClassification(int node)
{
	start[node] = timer++;

	rep(i, adj[node])
	{
		int child = adj[node][i];
		if (start[child] == -1)	// Not visited Before. Treed Edge
			dfs_EdgeClassification(child);
		else {
			if(finish[child] == -1)// then this is ancestor that called us and waiting us to finish. Then Cycle. Back Edge
				anyCycle = 1;
			else if(start[node] < start[child])	// then you are my descendant
				;	// Forward Edge
			else
				;	// Cross Edge
		}
	}

	finish[node] = timer++;
}

vectorll factorization(ll n) 	 max n is 1e12
{	// O( sqrt(n) )

	vectorll primes;

	for (ll i = 2; i  i * i <= n; ++i)	 Improve start by i = 3.
		while (n % i == 0)
			primes.push_back(i), n /= i;	 Get every prime inside n.	n  i^j	is a new number

	 Two ways to prove that n will be prime number if n  1
	 1) Think in n  pi^x as a NEW sub-problem. If we went to its sqrt and % applied, then we are facing a prime number
	 2) Prove that, for any n either all its primes before sqrt(n), or only the biggest prime after sqrt(n).
	if (n  > 1)
		primes.push_back(n);

	return primes;
}

typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;

	ordered_set X;
	X.insert(1);
	X.insert(2);
	X.insert(4);
	X.insert(8);
	X.insert(16);

	0 1 2 3 4
	1 2 4 8 16
	cout<<*X.find_by_order(1)<<endl; // 2
	cout<<*X.find_by_order(2)<<endl; // 4
	cout<<*X.find_by_order(4)<<endl; // 16
	cout<<(end(X)==X.find_by_order(6))<<endl; // true

	cout<<X.order_of_key(-5)<<endl;  // 0
	cout<<X.order_of_key(1)<<endl;   // 0
	cout<<X.order_of_key(3)<<endl;   // 2
	cout<<X.order_of_key(4)<<endl;   // 2
	cout<<X.order_of_key(400)<<endl; // 5

int t = 0;

ordered_set me;
...
me.insert({x, t++});
me.erase(me.lower_bound({x, 0}));
cout << me.order_of_key({x, 0}) << "\n";

*/
const double Eps =(1e-7);
int dcmp(double x,double y){ return fabs(x-y)<=Eps? 0: x<y ?-1:1; }
typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;
typedef tree<pair<int, int>,null_type,less<pair<int, int>>,rb_tree_tag,tree_order_statistics_node_update> ordered_setpair;
typedef long long  ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<string> vs;
typedef vector<pair<int,int> > vii;
typedef map<int, int> mii;
typedef map<string, int> msi;
typedef pair<int, int> pii;
#define mii map <int, int>
#define mll map <ll, ll>
#define pii pair <int, int>
#define pll pair <ll, ll>
#define vi vector <int>
#define vd vector <double>
#define vll vector <ll>
#define sll set <ll>
#define spii set <pii>
#define vpii vector <pair <int,int> >
#define vpll vector <pair <long long,long long> >
#define vvi vector <vector <int> >
#define vvpii vector <vector <pii > >
#define sfi1(v) scanf("%d",&v)
#define sfi2(v1,v2) scanf("%d %d",&v1,&v2)
#define sfi3(v1,v2,v3) scanf("%d %d %d",&v1,&v2,&v3)
#define sfll1(v) scanf("%I64d",&v);
#define sfll2(v1,v2) scanf("%I64d %I64d",&v1,&v2)
#define sfll3(v1,v2,v3) scanf("%I64d %I64d %I64d",&v1,&v2,&v3)
#define min3(a,b,c)     min(a,min(b,c))
#define max3(a,b,c)     max(a,max(b,c))
#define min4(a,b,c,d)   min(a,min(b,min(c,d)))
#define max4(a,b,c,d)   max(a,max(b,max(c,d)))
#define el	'\n'
#define lp(i,n) for(int i = 0;i < int(n);i++)
#define lp1(i,n) for(int i = 1;i <= int(n);i++)
#define rlp(i, n) for (int i = (n) - 1; i >= 0; i--)
#define rng(i,a,b) for(int i = int(a);i <= int(b);i++)
#define mp(x,y)  	make_pair((x),(y))
#define pb(x)    	push_back((x))
#define all(v)  	((v).begin()),((v).end())
#define sz(x)  		((int) (x).size())
#define bits(a) 	__builtin_popcountll(a)
#define fr first
#define sc second
#define pii pair<int, int>
#define sortva(v) sort(all(v))
#define sortvd(v) sort(v.rbegin(),v.rend())
#define sortaa(a,n) sort(a,a+n)
#define sortad(a,n) sort(a,a+n),reverse(a,a+n)
#define SS stringstream
#define ll long long
#define clr(x, y) memset(x, y, sizeof(x))
#define foreach(it,x) for(__typeof__((x).begin()) it = (x).begin(); it != (x).end(); ++it)
#define read freopen("input.in", "rt", stdin);
#define write freopen("output.in", "wt", stdout);
#define fastIO cout << fixed << setprecision(0), ios::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
const long long  P = (31);
const long long  key2 = 59;
int dx[] = { 0, 0, 1, -1, 1, -1, 1, -1 };
int dy[] = { 1, -1, 0, 0, -1, 1, 1, -1 };
int kx[] = { 2, 2, 1, -1, -2, -2, 1, -1 };
int ky[] = { 1, -1, 2, 2, 1, -1, -2, -2 };
ll gcd(ll a, ll b){if (a == 0)return b;return gcd(b % a, a);}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }

int const N = 5e3+9, mod = 1e9+7 ,  oo = 2e9+7;

//------------------------------------------------------------------------------------

set<pii>s;
int n,nofships,len;
bool ok (int nofships,int total){
return ((ll)nofships*(ll)len)+(ll)(nofships-1)<=(ll)total;
}

int get(int l,int r){

int len=r-l+1;
int lo=0,rr=4e5,med;
while(lo<rr){
	med=(lo+rr+1)>>1;
	if (ok(med,len))lo=med;
	else rr=med-1;
}
return lo;

}
int main()
{
	cin>>n>>nofships>>len;
	int y;
	cin>>y;
	s.insert(mp(1,n));
	int sum=get(1,n);
	for (int i=1;i<=y;i++){
		int x;
		cin>>x;
		auto it=s.upper_bound(mp(x,0));
		if (it==s.begin())return cout<< "dasd",0;
		pii t=*--it;
		s.erase(it);
if (t.fr<=x-1	)s.insert(mp(t.fr,x-1));
	if (x+1<=t.sc	)	s.insert(mp(x+1,t.sc));
		sum-=get(t.fr,t.sc);
		sum+=get(t.fr,x-1);
		sum+=get(x+1,t.sc);
		if (sum<nofships)return cout<< i,0;
	}
	cout<< -1;

/*
*/
return 0;
}


/*|In The Name of Allah|*/
/* Dear GCC compiler:
*
* If my code doesn't compile, this doesn't mean it's wrong.
* It just mean that you don't understand what I want.
* Here's my safety pig, I hope my code compile and get accepted.
* _._ _..._ .-',     _.._(`))
*'-. `     '  /-._.-'    ',/
*   )         \            '.
*  / _    _    |             \
* |  a    a    /              |
* \   .-.                     ;
*  '-('' ).-'       ,'       ;
*     '-;           |      .'
*        \           \    /
*        | 7  .__  _.-\   \
*        | |  |  ``/  /`  /
*       /,_|  |   /,_/   /
*          /,_/      '`-'
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
using namespace  __gnu_pbds;

long long power(long long x, long long y){
if (y == 0)
	return 1;
long long ret = power(x , y >> 1) %1000000007 ;
if (y % 2 == 0)
	return (ret * ret) % 1000000007;
else
	return (x * (ret * ret % 1000000007)) % 1000000007;
}

pair<int, int> norm(pair<int, int> p)
{
	if(p.first < 0)
	{
		p.first *= -1;
		p.second *= -1;
	}
	else if (p.first == 0 && p.second < 0)
	{
		p.second *= -1;
	}
	int d = __gcd(abs(p.first), abs(p.second));
	p.first /= d;
	p.second /= d;
	return p;
}

/*

int parent[N], sz[N];
int n, m, components;

void init(){
  iota(parent, parent+n, 0);
  fill(sz, sz+n, 1);
  components = n;
}

int find(int u){
  if(parent[u] == u)  return u;
  return parent[u] = find(parent[u]);
}

void join(int u, int v){
  u = find(u), v = find(v);
  if(u == v)  return;
  if(sz[u] < sz[v]) swap(u, v);
  parent[v] = u;
  sz[u] += sz[v];
  --components;
}
int dst[N];
int vis[N];
int parent[N];
vector<vector<pair<int,ll>>>v(N);
void dikstra(){
	set<pair<ll,ll>>s;
	clr(dst,oo);
	clr(vis,0);
	clr(parent,-1);
	dst[1]=0;
	parent[1]=-1;
	s.insert( mp(0,1 ) );
	while(!s.empty()){

		pair<ll,ll> x=*s.begin();
		s.erase(s.begin());
		ll u=x.sc;
		ll d=x.fr;
		if (vis[u])continue;
		vis[u]=1;
		for (int i=0;i<v[u].size();i++){
			ll to=v[u][i].fr;
			ll cost=v[u][i].sc;
			if (vis[to]||d+cost>=dst[to])continue;
			dst[to]=d+cost;
			parent[to]=u;
			s.insert(mp(d+cost,to));
		}
	}

return;
}
void primeFactors(int n)
{
	while (n % 2 == 0){
		n = n/2;
	}

	for (int i = 3; i <= sqrt(n); i = i + 2)
	{
		while (n % i == 0){
			cout << i << " ";
			n = n/i;
		}
	}
	if (n > 2){

	}
}

void Theaf(){
isPrime[0]=1;
isPrime[1]=1;
for (int i=2;i*i<=N;i++){
	if (isPrime[i]==1)continue;
	for (int cnt=2;i*cnt<=N;cnt++)isPrime[ cnt*i ]=1;
}

}
void dfs_EdgeClassification(int node)
{
	start[node] = timer++;

	rep(i, adj[node])
	{
		int child = adj[node][i];
		if (start[child] == -1)	// Not visited Before. Treed Edge
			dfs_EdgeClassification(child);
		else {
			if(finish[child] == -1)// then this is ancestor that called us and waiting us to finish. Then Cycle. Back Edge
				anyCycle = 1;
			else if(start[node] < start[child])	// then you are my descendant
				;	// Forward Edge
			else
				;	// Cross Edge
		}
	}

	finish[node] = timer++;
}

vectorll factorization(ll n) 	 max n is 1e12
{	// O( sqrt(n) )

	vectorll primes;

	for (ll i = 2; i  i * i <= n; ++i)	 Improve start by i = 3.
		while (n % i == 0)
			primes.push_back(i), n /= i;	 Get every prime inside n.	n  i^j	is a new number

	 Two ways to prove that n will be prime number if n  1
	 1) Think in n  pi^x as a NEW sub-problem. If we went to its sqrt and % applied, then we are facing a prime number
	 2) Prove that, for any n either all its primes before sqrt(n), or only the biggest prime after sqrt(n).
	if (n  > 1)
		primes.push_back(n);

	return primes;
}

typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;

	ordered_set X;
	X.insert(1);
	X.insert(2);
	X.insert(4);
	X.insert(8);
	X.insert(16);

	0 1 2 3 4
	1 2 4 8 16
	cout<<*X.find_by_order(1)<<endl; // 2
	cout<<*X.find_by_order(2)<<endl; // 4
	cout<<*X.find_by_order(4)<<endl; // 16
	cout<<(end(X)==X.find_by_order(6))<<endl; // true

	cout<<X.order_of_key(-5)<<endl;  // 0
	cout<<X.order_of_key(1)<<endl;   // 0
	cout<<X.order_of_key(3)<<endl;   // 2
	cout<<X.order_of_key(4)<<endl;   // 2
	cout<<X.order_of_key(400)<<endl; // 5

int t = 0;

ordered_set me;
...
me.insert({x, t++});
me.erase(me.lower_bound({x, 0}));
cout << me.order_of_key({x, 0}) << "\n";

*/
const double Eps =(1e-7);
int dcmp(double x,double y){ return fabs(x-y)<=Eps? 0: x<y ?-1:1; }
typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;
typedef tree<pair<int, int>,null_type,less<pair<int, int>>,rb_tree_tag,tree_order_statistics_node_update> ordered_setpair;
typedef long long  ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<string> vs;
typedef vector<pair<int,int> > vii;
typedef map<int, int> mii;
typedef map<string, int> msi;
typedef pair<int, int> pii;
#define mii map <int, int>
#define mll map <ll, ll>
#define pii pair <int, int>
#define pll pair <ll, ll>
#define vi vector <int>
#define vd vector <double>
#define vll vector <ll>
#define sll set <ll>
#define spii set <pii>
#define vpii vector <pair <int,int> >
#define vpll vector <pair <long long,long long> >
#define vvi vector <vector <int> >
#define vvpii vector <vector <pii > >
#define sfi1(v) scanf("%d",&v)
#define sfi2(v1,v2) scanf("%d %d",&v1,&v2)
#define sfi3(v1,v2,v3) scanf("%d %d %d",&v1,&v2,&v3)
#define sfll1(v) scanf("%I64d",&v);
#define sfll2(v1,v2) scanf("%I64d %I64d",&v1,&v2)
#define sfll3(v1,v2,v3) scanf("%I64d %I64d %I64d",&v1,&v2,&v3)
#define min3(a,b,c)     min(a,min(b,c))
#define max3(a,b,c)     max(a,max(b,c))
#define min4(a,b,c,d)   min(a,min(b,min(c,d)))
#define max4(a,b,c,d)   max(a,max(b,max(c,d)))
#define el	'\n'
#define lp(i,n) for(int i = 0;i < int(n);i++)
#define lp1(i,n) for(int i = 1;i <= int(n);i++)
#define rlp(i, n) for (int i = (n) - 1; i >= 0; i--)
#define rng(i,a,b) for(int i = int(a);i <= int(b);i++)
#define mp(x,y)  	make_pair((x),(y))
#define pb(x)    	push_back((x))
#define all(v)  	((v).begin()),((v).end())
#define sz(x)  		((int) (x).size())
#define bits(a) 	__builtin_popcountll(a)
#define fr first
#define sc second
#define pii pair<int, int>
#define sortva(v) sort(all(v))
#define sortvd(v) sort(v.rbegin(),v.rend())
#define sortaa(a,n) sort(a,a+n)
#define sortad(a,n) sort(a,a+n),reverse(a,a+n)
#define SS stringstream
#define ll long long
#define clr(x, y) memset(x, y, sizeof(x))
#define foreach(it,x) for(__typeof__((x).begin()) it = (x).begin(); it != (x).end(); ++it)
#define read freopen("input.in", "rt", stdin);
#define write freopen("output.in", "wt", stdout);
#define fastIO cout << fixed << setprecision(0), ios::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
const long long  P = (31);
const long long  key2 = 59;
int dx[] = { 0, 0, 1, -1, 1, -1, 1, -1 };
int dy[] = { 1, -1, 0, 0, -1, 1, 1, -1 };
int kx[] = { 2, 2, 1, -1, -2, -2, 1, -1 };
int ky[] = { 1, -1, 2, 2, 1, -1, -2, -2 };
ll gcd(ll a, ll b){if (a == 0)return b;return gcd(b % a, a);}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }

int const N = 5e3+9, mod = 1e9+7 ,  oo = 2e9+7;

//------------------------------------------------------------------------------------

set<pii>s;
int n,nofships,len;
bool ok (int nofships,int total){
return ((ll)nofships*(ll)len)+(ll)(nofships-1)<=(ll)total;
}

int get(int l,int r){

int len=r-l+1;
int lo=0,rr=4e5,med;
while(lo<rr){
	med=(lo+rr+1)>>1;
	if (ok(med,len))lo=med;
	else rr=med-1;
}
return lo;

}
int main()
{

	cin>>n>>nofships>>len;
	int y;
	cin>>y;
	s.insert(mp(1,n));
	int sum=get(1,n);
	for (int i=1;i<=y;i++){
		int x;
		cin>>x;
		auto it=s.upper_bound(mp(x,oo));
		pii t=*--it;
		s.erase(it);
if (t.fr<=x-1	)s.insert(mp(t.fr,x-1));
	if (x+1<=t.sc	)	s.insert(mp(x+1,t.sc));
		sum-=get(t.fr,t.sc);
		sum+=get(t.fr,x-1);
		sum+=get(x+1,t.sc);
		if (sum<nofships)return cout<< i,0;
	}
	cout<< -1;

/*
*/
return 0;
}


/*|In The Name of Allah|*/
/* Dear GCC compiler:
*
* If my code doesn't compile, this doesn't mean it's wrong.
* It just mean that you don't understand what I want.
* Here's my safety pig, I hope my code compile and get accepted.
* _._ _..._ .-',     _.._(`))
*'-. `     '  /-._.-'    ',/
*   )         \            '.
*  / _    _    |             \
* |  a    a    /              |
* \   .-.                     ;
*  '-('' ).-'       ,'       ;
*     '-;           |      .'
*        \           \    /
*        | 7  .__  _.-\   \
*        | |  |  ``/  /`  /
*       /,_|  |   /,_/   /
*          /,_/      '`-'
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
using namespace  __gnu_pbds;

long long power(long long x, long long y){
if (y == 0)
	return 1;
long long ret = power(x , y >> 1) %1000000007 ;
if (y % 2 == 0)
	return (ret * ret) % 1000000007;
else
	return (x * (ret * ret % 1000000007)) % 1000000007;
}

pair<int, int> norm(pair<int, int> p)
{
	if(p.first < 0)
	{
		p.first *= -1;
		p.second *= -1;
	}
	else if (p.first == 0 && p.second < 0)
	{
		p.second *= -1;
	}
	int d = __gcd(abs(p.first), abs(p.second));
	p.first /= d;
	p.second /= d;
	return p;
}

/*

int parent[N], sz[N];
int n, m, components;

void init(){
  iota(parent, parent+n, 0);
  fill(sz, sz+n, 1);
  components = n;
}

int find(int u){
  if(parent[u] == u)  return u;
  return parent[u] = find(parent[u]);
}

void join(int u, int v){
  u = find(u), v = find(v);
  if(u == v)  return;
  if(sz[u] < sz[v]) swap(u, v);
  parent[v] = u;
  sz[u] += sz[v];
  --components;
}
int dst[N];
int vis[N];
int parent[N];
vector<vector<pair<int,ll>>>v(N);
void dikstra(){
	set<pair<ll,ll>>s;
	clr(dst,oo);
	clr(vis,0);
	clr(parent,-1);
	dst[1]=0;
	parent[1]=-1;
	s.insert( mp(0,1 ) );
	while(!s.empty()){

		pair<ll,ll> x=*s.begin();
		s.erase(s.begin());
		ll u=x.sc;
		ll d=x.fr;
		if (vis[u])continue;
		vis[u]=1;
		for (int i=0;i<v[u].size();i++){
			ll to=v[u][i].fr;
			ll cost=v[u][i].sc;
			if (vis[to]||d+cost>=dst[to])continue;
			dst[to]=d+cost;
			parent[to]=u;
			s.insert(mp(d+cost,to));
		}
	}

return;
}
void primeFactors(int n)
{
	while (n % 2 == 0){
		n = n/2;
	}

	for (int i = 3; i <= sqrt(n); i = i + 2)
	{
		while (n % i == 0){
			cout << i << " ";
			n = n/i;
		}
	}
	if (n > 2){

	}
}

void Theaf(){
isPrime[0]=1;
isPrime[1]=1;
for (int i=2;i*i<=N;i++){
	if (isPrime[i]==1)continue;
	for (int cnt=2;i*cnt<=N;cnt++)isPrime[ cnt*i ]=1;
}

}
void dfs_EdgeClassification(int node)
{
	start[node] = timer++;

	rep(i, adj[node])
	{
		int child = adj[node][i];
		if (start[child] == -1)	// Not visited Before. Treed Edge
			dfs_EdgeClassification(child);
		else {
			if(finish[child] == -1)// then this is ancestor that called us and waiting us to finish. Then Cycle. Back Edge
				anyCycle = 1;
			else if(start[node] < start[child])	// then you are my descendant
				;	// Forward Edge
			else
				;	// Cross Edge
		}
	}

	finish[node] = timer++;
}

vectorll factorization(ll n) 	 max n is 1e12
{	// O( sqrt(n) )

	vectorll primes;

	for (ll i = 2; i  i * i <= n; ++i)	 Improve start by i = 3.
		while (n % i == 0)
			primes.push_back(i), n /= i;	 Get every prime inside n.	n  i^j	is a new number

	 Two ways to prove that n will be prime number if n  1
	 1) Think in n  pi^x as a NEW sub-problem. If we went to its sqrt and % applied, then we are facing a prime number
	 2) Prove that, for any n either all its primes before sqrt(n), or only the biggest prime after sqrt(n).
	if (n  > 1)
		primes.push_back(n);

	return primes;
}

typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;

	ordered_set X;
	X.insert(1);
	X.insert(2);
	X.insert(4);
	X.insert(8);
	X.insert(16);

	0 1 2 3 4
	1 2 4 8 16
	cout<<*X.find_by_order(1)<<endl; // 2
	cout<<*X.find_by_order(2)<<endl; // 4
	cout<<*X.find_by_order(4)<<endl; // 16
	cout<<(end(X)==X.find_by_order(6))<<endl; // true

	cout<<X.order_of_key(-5)<<endl;  // 0
	cout<<X.order_of_key(1)<<endl;   // 0
	cout<<X.order_of_key(3)<<endl;   // 2
	cout<<X.order_of_key(4)<<endl;   // 2
	cout<<X.order_of_key(400)<<endl; // 5

int t = 0;

ordered_set me;
...
me.insert({x, t++});
me.erase(me.lower_bound({x, 0}));
cout << me.order_of_key({x, 0}) << "\n";

*/
const double Eps =(1e-7);
int dcmp(double x,double y){ return fabs(x-y)<=Eps? 0: x<y ?-1:1; }
typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;
typedef tree<pair<int, int>,null_type,less<pair<int, int>>,rb_tree_tag,tree_order_statistics_node_update> ordered_setpair;
typedef long long  ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<string> vs;
typedef vector<pair<int,int> > vii;
typedef map<int, int> mii;
typedef map<string, int> msi;
typedef pair<int, int> pii;
#define mii map <int, int>
#define mll map <ll, ll>
#define pii pair <int, int>
#define pll pair <ll, ll>
#define vi vector <int>
#define vd vector <double>
#define vll vector <ll>
#define sll set <ll>
#define spii set <pii>
#define vpii vector <pair <int,int> >
#define vpll vector <pair <long long,long long> >
#define vvi vector <vector <int> >
#define vvpii vector <vector <pii > >
#define sfi1(v) scanf("%d",&v)
#define sfi2(v1,v2) scanf("%d %d",&v1,&v2)
#define sfi3(v1,v2,v3) scanf("%d %d %d",&v1,&v2,&v3)
#define sfll1(v) scanf("%I64d",&v);
#define sfll2(v1,v2) scanf("%I64d %I64d",&v1,&v2)
#define sfll3(v1,v2,v3) scanf("%I64d %I64d %I64d",&v1,&v2,&v3)
#define min3(a,b,c)     min(a,min(b,c))
#define max3(a,b,c)     max(a,max(b,c))
#define min4(a,b,c,d)   min(a,min(b,min(c,d)))
#define max4(a,b,c,d)   max(a,max(b,max(c,d)))
#define el	'\n'
#define lp(i,n) for(int i = 0;i < int(n);i++)
#define lp1(i,n) for(int i = 1;i <= int(n);i++)
#define rlp(i, n) for (int i = (n) - 1; i >= 0; i--)
#define rng(i,a,b) for(int i = int(a);i <= int(b);i++)
#define mp(x,y)  	make_pair((x),(y))
#define pb(x)    	push_back((x))
#define all(v)  	((v).begin()),((v).end())
#define sz(x)  		((int) (x).size())
#define bits(a) 	__builtin_popcountll(a)
#define fr first
#define sc second
#define pii pair<int, int>
#define sortva(v) sort(all(v))
#define sortvd(v) sort(v.rbegin(),v.rend())
#define sortaa(a,n) sort(a,a+n)
#define sortad(a,n) sort(a,a+n),reverse(a,a+n)
#define SS stringstream
#define ll long long
#define clr(x, y) memset(x, y, sizeof(x))
#define foreach(it,x) for(__typeof__((x).begin()) it = (x).begin(); it != (x).end(); ++it)
#define read freopen("input.in", "rt", stdin);
#define write freopen("output.in", "wt", stdout);
#define fastIO cout << fixed << setprecision(0), ios::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
const int key = 37;
const int key2 = 59;
int dx[] = { 0, 0, 1, -1, 1, -1, 1, -1 };
int dy[] = { 1, -1, 0, 0, -1, 1, 1, -1 };
int kx[] = { 2, 2, 1, -1, -2, -2, 1, -1 };
int ky[] = { 1, -1, 2, 2, 1, -1, -2, -2 };
ll gcd(ll a, ll b){if (a == 0)return b;return gcd(b % a, a);}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }

int const N = 5e5+9, mod = 998244353 ,  oo = 2e9+7;

//------------------------------------------------------------------------------------

set<pii>s;
int n,nofships,len;
bool ok (int nofships,int total){
return ((ll)nofships*(ll)len)+(ll)(nofships-1)<=(ll)total;
}

int get(int l,int r){

int len=r-l+1;
int lo=0,rr=4e5,med;
while(lo<rr){
	med=(lo+rr+1)>>1;
	if (ok(med,len))lo=med;
	else rr=med-1;
}
return lo;

}
int main()
{
	cin>>n>>nofships>>len;
	int y;
	cin>>y;
	s.insert(mp(1,n));
	int sum=get(1,n);
	for (int i=1;i<=y;i++){
		int x;
		cin>>x;
		auto it=s.upper_bound(mp(x,0));
		pii t=*--it;
		s.erase(it);
		s.insert(mp(t.fr,x-1));
		s.insert(mp(x+1,t.sc));
		sum-=get(t.fr,t.sc);
		if (t.fr<=x-1	)sum+=get(t.fr,x-1);
		if (x+1<=t.sc)sum+=get(x+1,t.sc);
		if (sum<nofships)return cout<< i,0;
	}
	cout<< -1;

/*
*/
return 0;
}


/*|In The Name of Allah|*/
/* Dear GCC compiler:
*
* If my code doesn't compile, this doesn't mean it's wrong.
* It just mean that you don't understand what I want.
* Here's my safety pig, I hope my code compile and get accepted.
* _._ _..._ .-',     _.._(`))
*'-. `     '  /-._.-'    ',/
*   )         \            '.
*  / _    _    |             \
* |  a    a    /              |
* \   .-.                     ;
*  '-('' ).-'       ,'       ;
*     '-;           |      .'
*        \           \    /
*        | 7  .__  _.-\   \
*        | |  |  ``/  /`  /
*       /,_|  |   /,_/   /
*          /,_/      '`-'
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
using namespace  __gnu_pbds;

long long power(long long x, long long y){
if (y == 0)
	return 1;
long long ret = power(x , y >> 1) %1000000007 ;
if (y % 2 == 0)
	return (ret * ret) % 1000000007;
else
	return (x * (ret * ret % 1000000007)) % 1000000007;
}

pair<int, int> norm(pair<int, int> p)
{
	if(p.first < 0)
	{
		p.first *= -1;
		p.second *= -1;
	}
	else if (p.first == 0 && p.second < 0)
	{
		p.second *= -1;
	}
	int d = __gcd(abs(p.first), abs(p.second));
	p.first /= d;
	p.second /= d;
	return p;
}

/*

int parent[N], sz[N];
int n, m, components;

void init(){
  iota(parent, parent+n, 0);
  fill(sz, sz+n, 1);
  components = n;
}

int find(int u){
  if(parent[u] == u)  return u;
  return parent[u] = find(parent[u]);
}

void join(int u, int v){
  u = find(u), v = find(v);
  if(u == v)  return;
  if(sz[u] < sz[v]) swap(u, v);
  parent[v] = u;
  sz[u] += sz[v];
  --components;
}
int dst[N];
int vis[N];
int parent[N];
vector<vector<pair<int,ll>>>v(N);
void dikstra(){
	set<pair<ll,ll>>s;
	clr(dst,oo);
	clr(vis,0);
	clr(parent,-1);
	dst[1]=0;
	parent[1]=-1;
	s.insert( mp(0,1 ) );
	while(!s.empty()){

		pair<ll,ll> x=*s.begin();
		s.erase(s.begin());
		ll u=x.sc;
		ll d=x.fr;
		if (vis[u])continue;
		vis[u]=1;
		for (int i=0;i<v[u].size();i++){
			ll to=v[u][i].fr;
			ll cost=v[u][i].sc;
			if (vis[to]||d+cost>=dst[to])continue;
			dst[to]=d+cost;
			parent[to]=u;
			s.insert(mp(d+cost,to));
		}
	}

return;
}
void primeFactors(int n)
{
	while (n % 2 == 0){
		n = n/2;
	}

	for (int i = 3; i <= sqrt(n); i = i + 2)
	{
		while (n % i == 0){
			cout << i << " ";
			n = n/i;
		}
	}
	if (n > 2){

	}
}

void Theaf(){
isPrime[0]=1;
isPrime[1]=1;
for (int i=2;i*i<=N;i++){
	if (isPrime[i]==1)continue;
	for (int cnt=2;i*cnt<=N;cnt++)isPrime[ cnt*i ]=1;
}

}
void dfs_EdgeClassification(int node)
{
	start[node] = timer++;

	rep(i, adj[node])
	{
		int child = adj[node][i];
		if (start[child] == -1)	// Not visited Before. Treed Edge
			dfs_EdgeClassification(child);
		else {
			if(finish[child] == -1)// then this is ancestor that called us and waiting us to finish. Then Cycle. Back Edge
				anyCycle = 1;
			else if(start[node] < start[child])	// then you are my descendant
				;	// Forward Edge
			else
				;	// Cross Edge
		}
	}

	finish[node] = timer++;
}

vectorll factorization(ll n) 	 max n is 1e12
{	// O( sqrt(n) )

	vectorll primes;

	for (ll i = 2; i  i * i <= n; ++i)	 Improve start by i = 3.
		while (n % i == 0)
			primes.push_back(i), n /= i;	 Get every prime inside n.	n  i^j	is a new number

	 Two ways to prove that n will be prime number if n  1
	 1) Think in n  pi^x as a NEW sub-problem. If we went to its sqrt and % applied, then we are facing a prime number
	 2) Prove that, for any n either all its primes before sqrt(n), or only the biggest prime after sqrt(n).
	if (n  > 1)
		primes.push_back(n);

	return primes;
}

typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;

	ordered_set X;
	X.insert(1);
	X.insert(2);
	X.insert(4);
	X.insert(8);
	X.insert(16);

	0 1 2 3 4
	1 2 4 8 16
	cout<<*X.find_by_order(1)<<endl; // 2
	cout<<*X.find_by_order(2)<<endl; // 4
	cout<<*X.find_by_order(4)<<endl; // 16
	cout<<(end(X)==X.find_by_order(6))<<endl; // true

	cout<<X.order_of_key(-5)<<endl;  // 0
	cout<<X.order_of_key(1)<<endl;   // 0
	cout<<X.order_of_key(3)<<endl;   // 2
	cout<<X.order_of_key(4)<<endl;   // 2
	cout<<X.order_of_key(400)<<endl; // 5

int t = 0;

ordered_set me;
...
me.insert({x, t++});
me.erase(me.lower_bound({x, 0}));
cout << me.order_of_key({x, 0}) << "\n";

*/
const double Eps =(1e-7);
int dcmp(double x,double y){ return fabs(x-y)<=Eps? 0: x<y ?-1:1; }
typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;
typedef tree<pair<int, int>,null_type,less<pair<int, int>>,rb_tree_tag,tree_order_statistics_node_update> ordered_setpair;
typedef long long  ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<string> vs;
typedef vector<pair<int,int> > vii;
typedef map<int, int> mii;
typedef map<string, int> msi;
typedef pair<int, int> pii;
#define mii map <int, int>
#define mll map <ll, ll>
#define pii pair <int, int>
#define pll pair <ll, ll>
#define vi vector <int>
#define vd vector <double>
#define vll vector <ll>
#define sll set <ll>
#define spii set <pii>
#define vpii vector <pair <int,int> >
#define vpll vector <pair <long long,long long> >
#define vvi vector <vector <int> >
#define vvpii vector <vector <pii > >
#define sfi1(v) scanf("%d",&v)
#define sfi2(v1,v2) scanf("%d %d",&v1,&v2)
#define sfi3(v1,v2,v3) scanf("%d %d %d",&v1,&v2,&v3)
#define sfll1(v) scanf("%I64d",&v);
#define sfll2(v1,v2) scanf("%I64d %I64d",&v1,&v2)
#define sfll3(v1,v2,v3) scanf("%I64d %I64d %I64d",&v1,&v2,&v3)
#define min3(a,b,c)     min(a,min(b,c))
#define max3(a,b,c)     max(a,max(b,c))
#define min4(a,b,c,d)   min(a,min(b,min(c,d)))
#define max4(a,b,c,d)   max(a,max(b,max(c,d)))
#define el	'\n'
#define lp(i,n) for(int i = 0;i < int(n);i++)
#define lp1(i,n) for(int i = 1;i <= int(n);i++)
#define rlp(i, n) for (int i = (n) - 1; i >= 0; i--)
#define rng(i,a,b) for(int i = int(a);i <= int(b);i++)
#define mp(x,y)  	make_pair((x),(y))
#define pb(x)    	push_back((x))
#define all(v)  	((v).begin()),((v).end())
#define sz(x)  		((int) (x).size())
#define bits(a) 	__builtin_popcountll(a)
#define fr first
#define sc second
#define pii pair<int, int>
#define sortva(v) sort(all(v))
#define sortvd(v) sort(v.rbegin(),v.rend())
#define sortaa(a,n) sort(a,a+n)
#define sortad(a,n) sort(a,a+n),reverse(a,a+n)
#define SS stringstream
#define ll long long
#define clr(x, y) memset(x, y, sizeof(x))
#define foreach(it,x) for(__typeof__((x).begin()) it = (x).begin(); it != (x).end(); ++it)
#define read freopen("input.in", "rt", stdin);
#define write freopen("output.in", "wt", stdout);
#define fastIO cout << fixed << setprecision(0), ios::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
const int key = 37;
const int key2 = 59;
int dx[] = { 0, 0, 1, -1, 1, -1, 1, -1 };
int dy[] = { 1, -1, 0, 0, -1, 1, 1, -1 };
int kx[] = { 2, 2, 1, -1, -2, -2, 1, -1 };
int ky[] = { 1, -1, 2, 2, 1, -1, -2, -2 };
ll gcd(ll a, ll b){if (a == 0)return b;return gcd(b % a, a);}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }

int const N = 5e5+9, mod = 998244353 ,  oo = 2e9+7;

//------------------------------------------------------------------------------------

set<int>s;
set<int>ss;
int n,nofships,len;

bool ok (int nofships,int total){
return ((ll)nofships*(ll)len)+(ll)(nofships-1)<=(ll)total;
}

int get(int l,int r){
if (l==0)l++;
if (r==n+1)r--;
if (ss.find(r)!=ss.end())r--;
int len=r-l+1;
int lo=0,rr=4e5,med;
while(lo<rr){
	med=(lo+rr+1)>>1;
	if (ok(med,len))lo=med;
	else rr=med-1;
}
return lo;

}
int main()
{
	cin>>n>>nofships>>len;
	int y;
	cin>>y;
	s.insert(0);
	s.insert(n+1);

	int sum=get(1,n);
	for (int i=1;i<=y;i++){
		int x;
		cin>>x;
		ss.insert(x);
		auto it=s.upper_bound(x);
		int r=*it;
		int l=*--it;
		sum-=get(l,r);
		sum+=get(l,x-1);
		sum+=get(x+1,r);
		if (sum<nofships)return cout<< i,0;
		s.insert(x-1);
		s.insert(x);
		s.insert(x+1);
	}
	cout<< -1;

/*
*/
return 0;
}


/*|In The Name of Allah|*/
/* Dear GCC compiler:
*
* If my code doesn't compile, this doesn't mean it's wrong.
* It just mean that you don't understand what I want.
* Here's my safety pig, I hope my code compile and get accepted.
* _._ _..._ .-',     _.._(`))
*'-. `     '  /-._.-'    ',/
*   )         \            '.
*  / _    _    |             \
* |  a    a    /              |
* \   .-.                     ;
*  '-('' ).-'       ,'       ;
*     '-;           |      .'
*        \           \    /
*        | 7  .__  _.-\   \
*        | |  |  ``/  /`  /
*       /,_|  |   /,_/   /
*          /,_/      '`-'
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
using namespace  __gnu_pbds;

long long power(long long x, long long y){
if (y == 0)
	return 1;
long long ret = power(x , y >> 1) %1000000007 ;
if (y % 2 == 0)
	return (ret * ret) % 1000000007;
else
	return (x * (ret * ret % 1000000007)) % 1000000007;
}

pair<int, int> norm(pair<int, int> p)
{
	if(p.first < 0)
	{
		p.first *= -1;
		p.second *= -1;
	}
	else if (p.first == 0 && p.second < 0)
	{
		p.second *= -1;
	}
	int d = __gcd(abs(p.first), abs(p.second));
	p.first /= d;
	p.second /= d;
	return p;
}

/*

int parent[N], sz[N];
int n, m, components;

void init(){
  iota(parent, parent+n, 0);
  fill(sz, sz+n, 1);
  components = n;
}

int find(int u){
  if(parent[u] == u)  return u;
  return parent[u] = find(parent[u]);
}

void join(int u, int v){
  u = find(u), v = find(v);
  if(u == v)  return;
  if(sz[u] < sz[v]) swap(u, v);
  parent[v] = u;
  sz[u] += sz[v];
  --components;
}
int dst[N];
int vis[N];
int parent[N];
vector<vector<pair<int,ll>>>v(N);
void dikstra(){
	set<pair<ll,ll>>s;
	clr(dst,oo);
	clr(vis,0);
	clr(parent,-1);
	dst[1]=0;
	parent[1]=-1;
	s.insert( mp(0,1 ) );
	while(!s.empty()){

		pair<ll,ll> x=*s.begin();
		s.erase(s.begin());
		ll u=x.sc;
		ll d=x.fr;
		if (vis[u])continue;
		vis[u]=1;
		for (int i=0;i<v[u].size();i++){
			ll to=v[u][i].fr;
			ll cost=v[u][i].sc;
			if (vis[to]||d+cost>=dst[to])continue;
			dst[to]=d+cost;
			parent[to]=u;
			s.insert(mp(d+cost,to));
		}
	}

return;
}
void primeFactors(int n)
{
	while (n % 2 == 0){
		n = n/2;
	}

	for (int i = 3; i <= sqrt(n); i = i + 2)
	{
		while (n % i == 0){
			cout << i << " ";
			n = n/i;
		}
	}
	if (n > 2){

	}
}

void Theaf(){
isPrime[0]=1;
isPrime[1]=1;
for (int i=2;i*i<=N;i++){
	if (isPrime[i]==1)continue;
	for (int cnt=2;i*cnt<=N;cnt++)isPrime[ cnt*i ]=1;
}

}
void dfs_EdgeClassification(int node)
{
	start[node] = timer++;

	rep(i, adj[node])
	{
		int child = adj[node][i];
		if (start[child] == -1)	// Not visited Before. Treed Edge
			dfs_EdgeClassification(child);
		else {
			if(finish[child] == -1)// then this is ancestor that called us and waiting us to finish. Then Cycle. Back Edge
				anyCycle = 1;
			else if(start[node] < start[child])	// then you are my descendant
				;	// Forward Edge
			else
				;	// Cross Edge
		}
	}

	finish[node] = timer++;
}

vectorll factorization(ll n) 	 max n is 1e12
{	// O( sqrt(n) )

	vectorll primes;

	for (ll i = 2; i  i * i <= n; ++i)	 Improve start by i = 3.
		while (n % i == 0)
			primes.push_back(i), n /= i;	 Get every prime inside n.	n  i^j	is a new number

	 Two ways to prove that n will be prime number if n  1
	 1) Think in n  pi^x as a NEW sub-problem. If we went to its sqrt and % applied, then we are facing a prime number
	 2) Prove that, for any n either all its primes before sqrt(n), or only the biggest prime after sqrt(n).
	if (n  > 1)
		primes.push_back(n);

	return primes;
}

typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;

	ordered_set X;
	X.insert(1);
	X.insert(2);
	X.insert(4);
	X.insert(8);
	X.insert(16);

	0 1 2 3 4
	1 2 4 8 16
	cout<<*X.find_by_order(1)<<endl; // 2
	cout<<*X.find_by_order(2)<<endl; // 4
	cout<<*X.find_by_order(4)<<endl; // 16
	cout<<(end(X)==X.find_by_order(6))<<endl; // true

	cout<<X.order_of_key(-5)<<endl;  // 0
	cout<<X.order_of_key(1)<<endl;   // 0
	cout<<X.order_of_key(3)<<endl;   // 2
	cout<<X.order_of_key(4)<<endl;   // 2
	cout<<X.order_of_key(400)<<endl; // 5

int t = 0;

ordered_set me;
...
me.insert({x, t++});
me.erase(me.lower_bound({x, 0}));
cout << me.order_of_key({x, 0}) << "\n";

*/
const double Eps =(1e-7);
int dcmp(double x,double y){ return fabs(x-y)<=Eps? 0: x<y ?-1:1; }
typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;
typedef tree<pair<int, int>,null_type,less<pair<int, int>>,rb_tree_tag,tree_order_statistics_node_update> ordered_setpair;
typedef long long  ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<string> vs;
typedef vector<pair<int,int> > vii;
typedef map<int, int> mii;
typedef map<string, int> msi;
typedef pair<int, int> pii;
#define mii map <int, int>
#define mll map <ll, ll>
#define pii pair <int, int>
#define pll pair <ll, ll>
#define vi vector <int>
#define vd vector <double>
#define vll vector <ll>
#define sll set <ll>
#define spii set <pii>
#define vpii vector <pair <int,int> >
#define vpll vector <pair <long long,long long> >
#define vvi vector <vector <int> >
#define vvpii vector <vector <pii > >
#define sfi1(v) scanf("%d",&v)
#define sfi2(v1,v2) scanf("%d %d",&v1,&v2)
#define sfi3(v1,v2,v3) scanf("%d %d %d",&v1,&v2,&v3)
#define sfll1(v) scanf("%I64d",&v);
#define sfll2(v1,v2) scanf("%I64d %I64d",&v1,&v2)
#define sfll3(v1,v2,v3) scanf("%I64d %I64d %I64d",&v1,&v2,&v3)
#define min3(a,b,c)     min(a,min(b,c))
#define max3(a,b,c)     max(a,max(b,c))
#define min4(a,b,c,d)   min(a,min(b,min(c,d)))
#define max4(a,b,c,d)   max(a,max(b,max(c,d)))
#define el	'\n'
#define lp(i,n) for(int i = 0;i < int(n);i++)
#define lp1(i,n) for(int i = 1;i <= int(n);i++)
#define rlp(i, n) for (int i = (n) - 1; i >= 0; i--)
#define rng(i,a,b) for(int i = int(a);i <= int(b);i++)
#define mp(x,y)  	make_pair((x),(y))
#define pb(x)    	push_back((x))
#define all(v)  	((v).begin()),((v).end())
#define sz(x)  		((int) (x).size())
#define bits(a) 	__builtin_popcountll(a)
#define fr first
#define sc second
#define pii pair<int, int>
#define sortva(v) sort(all(v))
#define sortvd(v) sort(v.rbegin(),v.rend())
#define sortaa(a,n) sort(a,a+n)
#define sortad(a,n) sort(a,a+n),reverse(a,a+n)
#define SS stringstream
#define ll long long
#define clr(x, y) memset(x, y, sizeof(x))
#define foreach(it,x) for(__typeof__((x).begin()) it = (x).begin(); it != (x).end(); ++it)
#define read freopen("input.in", "rt", stdin);
#define write freopen("output.in", "wt", stdout);
#define fastIO cout << fixed << setprecision(0), ios::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
const int key = 37;
const int key2 = 59;
int dx[] = { 0, 0, 1, -1, 1, -1, 1, -1 };
int dy[] = { 1, -1, 0, 0, -1, 1, 1, -1 };
int kx[] = { 2, 2, 1, -1, -2, -2, 1, -1 };
int ky[] = { 1, -1, 2, 2, 1, -1, -2, -2 };
ll gcd(ll a, ll b){if (a == 0)return b;return gcd(b % a, a);}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }

int const N = 5e5+9, mod = 998244353 ,  oo = 2e9+7;

//------------------------------------------------------------------------------------

set<pii>s;
int n,nofships,len;
bool ok (int nofships,int total){
return ((ll)nofships*(ll)len)+(ll)(nofships-1)<=(ll)total;
}

int get(int l,int r){

int len=r-l+1;
int lo=0,rr=4e5,med;
while(lo<rr){
	med=(lo+rr+1)>>1;
	if (ok(med,len))lo=med;
	else rr=med-1;
}
return lo;

}
int main()
{
	cin>>n>>nofships>>len;
	int y;
	cin>>y;
	s.insert(mp(1,n));
	s.insert(mp(0,0));
	s.insert(mp(oo,oo));
	int sum=get(1,n);
	for (int i=1;i<=y;i++){
		int x;
		cin>>x;
		auto it=s.upper_bound(mp(x,0));
		 pii t=*--it;
		s.erase(it);
if (t.fr<=x-1	)s.insert(mp(t.fr,x-1));
	if (x+1<=t.sc	)	s.insert(mp(x+1,t.sc));
		sum-=get(t.fr,t.sc);
		sum+=get(t.fr,x-1);
		sum+=get(x+1,t.sc);
		if (sum<nofships)return cout<< i,0;
	}
	cout<< -1;

/*
*/
return 0;
}


/*|In The Name of Allah|*/
/* Dear GCC compiler:
*
* If my code doesn't compile, this doesn't mean it's wrong.
* It just mean that you don't understand what I want.
* Here's my safety pig, I hope my code compile and get accepted.
* _._ _..._ .-',     _.._(`))
*'-. `     '  /-._.-'    ',/
*   )         \            '.
*  / _    _    |             \
* |  a    a    /              |
* \   .-.                     ;
*  '-('' ).-'       ,'       ;
*     '-;           |      .'
*        \           \    /
*        | 7  .__  _.-\   \
*        | |  |  ``/  /`  /
*       /,_|  |   /,_/   /
*          /,_/      '`-'
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
using namespace  __gnu_pbds;

long long power(long long x, long long y){
if (y == 0)
	return 1;
long long ret = power(x , y >> 1) %1000000007 ;
if (y % 2 == 0)
	return (ret * ret) % 1000000007;
else
	return (x * (ret * ret % 1000000007)) % 1000000007;
}

pair<int, int> norm(pair<int, int> p)
{
	if(p.first < 0)
	{
		p.first *= -1;
		p.second *= -1;
	}
	else if (p.first == 0 && p.second < 0)
	{
		p.second *= -1;
	}
	int d = __gcd(abs(p.first), abs(p.second));
	p.first /= d;
	p.second /= d;
	return p;
}

/*

int parent[N], sz[N];
int n, m, components;

void init(){
  iota(parent, parent+n, 0);
  fill(sz, sz+n, 1);
  components = n;
}

int find(int u){
  if(parent[u] == u)  return u;
  return parent[u] = find(parent[u]);
}

void join(int u, int v){
  u = find(u), v = find(v);
  if(u == v)  return;
  if(sz[u] < sz[v]) swap(u, v);
  parent[v] = u;
  sz[u] += sz[v];
  --components;
}
int dst[N];
int vis[N];
int parent[N];
vector<vector<pair<int,ll>>>v(N);
void dikstra(){
	set<pair<ll,ll>>s;
	clr(dst,oo);
	clr(vis,0);
	clr(parent,-1);
	dst[1]=0;
	parent[1]=-1;
	s.insert( mp(0,1 ) );
	while(!s.empty()){

		pair<ll,ll> x=*s.begin();
		s.erase(s.begin());
		ll u=x.sc;
		ll d=x.fr;
		if (vis[u])continue;
		vis[u]=1;
		for (int i=0;i<v[u].size();i++){
			ll to=v[u][i].fr;
			ll cost=v[u][i].sc;
			if (vis[to]||d+cost>=dst[to])continue;
			dst[to]=d+cost;
			parent[to]=u;
			s.insert(mp(d+cost,to));
		}
	}

return;
}
void primeFactors(int n)
{
	while (n % 2 == 0){
		n = n/2;
	}

	for (int i = 3; i <= sqrt(n); i = i + 2)
	{
		while (n % i == 0){
			cout << i << " ";
			n = n/i;
		}
	}
	if (n > 2){

	}
}

void Theaf(){
isPrime[0]=1;
isPrime[1]=1;
for (int i=2;i*i<=N;i++){
	if (isPrime[i]==1)continue;
	for (int cnt=2;i*cnt<=N;cnt++)isPrime[ cnt*i ]=1;
}

}
void dfs_EdgeClassification(int node)
{
	start[node] = timer++;

	rep(i, adj[node])
	{
		int child = adj[node][i];
		if (start[child] == -1)	// Not visited Before. Treed Edge
			dfs_EdgeClassification(child);
		else {
			if(finish[child] == -1)// then this is ancestor that called us and waiting us to finish. Then Cycle. Back Edge
				anyCycle = 1;
			else if(start[node] < start[child])	// then you are my descendant
				;	// Forward Edge
			else
				;	// Cross Edge
		}
	}

	finish[node] = timer++;
}

vectorll factorization(ll n) 	 max n is 1e12
{	// O( sqrt(n) )

	vectorll primes;

	for (ll i = 2; i  i * i <= n; ++i)	 Improve start by i = 3.
		while (n % i == 0)
			primes.push_back(i), n /= i;	 Get every prime inside n.	n  i^j	is a new number

	 Two ways to prove that n will be prime number if n  1
	 1) Think in n  pi^x as a NEW sub-problem. If we went to its sqrt and % applied, then we are facing a prime number
	 2) Prove that, for any n either all its primes before sqrt(n), or only the biggest prime after sqrt(n).
	if (n  > 1)
		primes.push_back(n);

	return primes;
}

typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;

	ordered_set X;
	X.insert(1);
	X.insert(2);
	X.insert(4);
	X.insert(8);
	X.insert(16);

	0 1 2 3 4
	1 2 4 8 16
	cout<<*X.find_by_order(1)<<endl; // 2
	cout<<*X.find_by_order(2)<<endl; // 4
	cout<<*X.find_by_order(4)<<endl; // 16
	cout<<(end(X)==X.find_by_order(6))<<endl; // true

	cout<<X.order_of_key(-5)<<endl;  // 0
	cout<<X.order_of_key(1)<<endl;   // 0
	cout<<X.order_of_key(3)<<endl;   // 2
	cout<<X.order_of_key(4)<<endl;   // 2
	cout<<X.order_of_key(400)<<endl; // 5

int t = 0;

ordered_set me;
...
me.insert({x, t++});
me.erase(me.lower_bound({x, 0}));
cout << me.order_of_key({x, 0}) << "\n";

*/
const double Eps =(1e-7);
int dcmp(double x,double y){ return fabs(x-y)<=Eps? 0: x<y ?-1:1; }
typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;
typedef tree<pair<int, int>,null_type,less<pair<int, int>>,rb_tree_tag,tree_order_statistics_node_update> ordered_setpair;
typedef long long  ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<string> vs;
typedef vector<pair<int,int> > vii;
typedef map<int, int> mii;
typedef map<string, int> msi;
typedef pair<int, int> pii;
#define mii map <int, int>
#define mll map <ll, ll>
#define pii pair <int, int>
#define pll pair <ll, ll>
#define vi vector <int>
#define vd vector <double>
#define vll vector <ll>
#define sll set <ll>
#define spii set <pii>
#define vpii vector <pair <int,int> >
#define vpll vector <pair <long long,long long> >
#define vvi vector <vector <int> >
#define vvpii vector <vector <pii > >
#define sfi1(v) scanf("%d",&v)
#define sfi2(v1,v2) scanf("%d %d",&v1,&v2)
#define sfi3(v1,v2,v3) scanf("%d %d %d",&v1,&v2,&v3)
#define sfll1(v) scanf("%I64d",&v);
#define sfll2(v1,v2) scanf("%I64d %I64d",&v1,&v2)
#define sfll3(v1,v2,v3) scanf("%I64d %I64d %I64d",&v1,&v2,&v3)
#define min3(a,b,c)     min(a,min(b,c))
#define max3(a,b,c)     max(a,max(b,c))
#define min4(a,b,c,d)   min(a,min(b,min(c,d)))
#define max4(a,b,c,d)   max(a,max(b,max(c,d)))
#define el	'\n'
#define lp(i,n) for(int i = 0;i < int(n);i++)
#define lp1(i,n) for(int i = 1;i <= int(n);i++)
#define rlp(i, n) for (int i = (n) - 1; i >= 0; i--)
#define rng(i,a,b) for(int i = int(a);i <= int(b);i++)
#define mp(x,y)  	make_pair((x),(y))
#define pb(x)    	push_back((x))
#define all(v)  	((v).begin()),((v).end())
#define sz(x)  		((int) (x).size())
#define bits(a) 	__builtin_popcountll(a)
#define fr first
#define sc second
#define pii pair<int, int>
#define sortva(v) sort(all(v))
#define sortvd(v) sort(v.rbegin(),v.rend())
#define sortaa(a,n) sort(a,a+n)
#define sortad(a,n) sort(a,a+n),reverse(a,a+n)
#define SS stringstream
#define ll long long
#define clr(x, y) memset(x, y, sizeof(x))
#define foreach(it,x) for(__typeof__((x).begin()) it = (x).begin(); it != (x).end(); ++it)
#define read freopen("input.in", "rt", stdin);
#define write freopen("output.in", "wt", stdout);
#define fastIO cout << fixed << setprecision(0), ios::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
const int key = 37;
const int key2 = 59;
int dx[] = { 0, 0, 1, -1, 1, -1, 1, -1 };
int dy[] = { 1, -1, 0, 0, -1, 1, 1, -1 };
int kx[] = { 2, 2, 1, -1, -2, -2, 1, -1 };
int ky[] = { 1, -1, 2, 2, 1, -1, -2, -2 };
ll gcd(ll a, ll b){if (a == 0)return b;return gcd(b % a, a);}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }

int const N = 5e5+9, mod = 998244353 ,  oo = 2e9+7;

//------------------------------------------------------------------------------------

set<pii>s;
int n,nofships,len;
bool ok (int nofships,int total){
return ((ll)nofships*(ll)len)+(ll)(nofships-1)<=(ll)total;
}

int get(int l,int r){

int len=r-l+1;
int lo=0,rr=4e5,med;
while(lo<rr){
	med=(lo+rr+1)>>1;
	if (ok(med,len))lo=med;
	else rr=med-1;
}
return lo;

}
int main()
{
	cin>>n>>nofships>>len;
	int y;
	cin>>y;
	s.insert(mp(1,n));
	s.insert(mp(0,0));
	s.insert(mp(oo,oo));
	int sum=get(1,n);
	for (int i=1;i<=y;i++){
		int x;
		cin>>x;
		auto it=s.upper_bound(mp(x,0));
		if pii t=*--it;
		s.erase(it);
if (t.fr<=x-1	)s.insert(mp(t.fr,x-1));
	if (x+1<=t.sc	)	s.insert(mp(x+1,t.sc));
		sum-=get(t.fr,t.sc);
		sum+=get(t.fr,x-1);
		sum+=get(x+1,t.sc);
		if (sum<nofships)return cout<< i,0;
	}
	cout<< -1;

/*
*/
return 0;
}


/*|In The Name of Allah|*/
/* Dear GCC compiler:
*
* If my code doesn't compile, this doesn't mean it's wrong.
* It just mean that you don't understand what I want.
* Here's my safety pig, I hope my code compile and get accepted.
* _._ _..._ .-',     _.._(`))
*'-. `     '  /-._.-'    ',/
*   )         \            '.
*  / _    _    |             \
* |  a    a    /              |
* \   .-.                     ;
*  '-('' ).-'       ,'       ;
*     '-;           |      .'
*        \           \    /
*        | 7  .__  _.-\   \
*        | |  |  ``/  /`  /
*       /,_|  |   /,_/   /
*          /,_/      '`-'
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
using namespace  __gnu_pbds;

long long power(long long x, long long y){
if (y == 0)
	return 1;
long long ret = power(x , y >> 1) %1000000007 ;
if (y % 2 == 0)
	return (ret * ret) % 1000000007;
else
	return (x * (ret * ret % 1000000007)) % 1000000007;
}

pair<int, int> norm(pair<int, int> p)
{
	if(p.first < 0)
	{
		p.first *= -1;
		p.second *= -1;
	}
	else if (p.first == 0 && p.second < 0)
	{
		p.second *= -1;
	}
	int d = __gcd(abs(p.first), abs(p.second));
	p.first /= d;
	p.second /= d;
	return p;
}

/*

int parent[N], sz[N];
int n, m, components;

void init(){
  iota(parent, parent+n, 0);
  fill(sz, sz+n, 1);
  components = n;
}

int find(int u){
  if(parent[u] == u)  return u;
  return parent[u] = find(parent[u]);
}

void join(int u, int v){
  u = find(u), v = find(v);
  if(u == v)  return;
  if(sz[u] < sz[v]) swap(u, v);
  parent[v] = u;
  sz[u] += sz[v];
  --components;
}
int dst[N];
int vis[N];
int parent[N];
vector<vector<pair<int,ll>>>v(N);
void dikstra(){
	set<pair<ll,ll>>s;
	clr(dst,oo);
	clr(vis,0);
	clr(parent,-1);
	dst[1]=0;
	parent[1]=-1;
	s.insert( mp(0,1 ) );
	while(!s.empty()){

		pair<ll,ll> x=*s.begin();
		s.erase(s.begin());
		ll u=x.sc;
		ll d=x.fr;
		if (vis[u])continue;
		vis[u]=1;
		for (int i=0;i<v[u].size();i++){
			ll to=v[u][i].fr;
			ll cost=v[u][i].sc;
			if (vis[to]||d+cost>=dst[to])continue;
			dst[to]=d+cost;
			parent[to]=u;
			s.insert(mp(d+cost,to));
		}
	}

return;
}
void primeFactors(int n)
{
	while (n % 2 == 0){
		n = n/2;
	}

	for (int i = 3; i <= sqrt(n); i = i + 2)
	{
		while (n % i == 0){
			cout << i << " ";
			n = n/i;
		}
	}
	if (n > 2){

	}
}

void Theaf(){
isPrime[0]=1;
isPrime[1]=1;
for (int i=2;i*i<=N;i++){
	if (isPrime[i]==1)continue;
	for (int cnt=2;i*cnt<=N;cnt++)isPrime[ cnt*i ]=1;
}

}
void dfs_EdgeClassification(int node)
{
	start[node] = timer++;

	rep(i, adj[node])
	{
		int child = adj[node][i];
		if (start[child] == -1)	// Not visited Before. Treed Edge
			dfs_EdgeClassification(child);
		else {
			if(finish[child] == -1)// then this is ancestor that called us and waiting us to finish. Then Cycle. Back Edge
				anyCycle = 1;
			else if(start[node] < start[child])	// then you are my descendant
				;	// Forward Edge
			else
				;	// Cross Edge
		}
	}

	finish[node] = timer++;
}

vectorll factorization(ll n) 	 max n is 1e12
{	// O( sqrt(n) )

	vectorll primes;

	for (ll i = 2; i  i * i <= n; ++i)	 Improve start by i = 3.
		while (n % i == 0)
			primes.push_back(i), n /= i;	 Get every prime inside n.	n  i^j	is a new number

	 Two ways to prove that n will be prime number if n  1
	 1) Think in n  pi^x as a NEW sub-problem. If we went to its sqrt and % applied, then we are facing a prime number
	 2) Prove that, for any n either all its primes before sqrt(n), or only the biggest prime after sqrt(n).
	if (n  > 1)
		primes.push_back(n);

	return primes;
}

typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;

	ordered_set X;
	X.insert(1);
	X.insert(2);
	X.insert(4);
	X.insert(8);
	X.insert(16);

	0 1 2 3 4
	1 2 4 8 16
	cout<<*X.find_by_order(1)<<endl; // 2
	cout<<*X.find_by_order(2)<<endl; // 4
	cout<<*X.find_by_order(4)<<endl; // 16
	cout<<(end(X)==X.find_by_order(6))<<endl; // true

	cout<<X.order_of_key(-5)<<endl;  // 0
	cout<<X.order_of_key(1)<<endl;   // 0
	cout<<X.order_of_key(3)<<endl;   // 2
	cout<<X.order_of_key(4)<<endl;   // 2
	cout<<X.order_of_key(400)<<endl; // 5

int t = 0;

ordered_set me;
...
me.insert({x, t++});
me.erase(me.lower_bound({x, 0}));
cout << me.order_of_key({x, 0}) << "\n";

*/
const double Eps =(1e-7);
int dcmp(double x,double y){ return fabs(x-y)<=Eps? 0: x<y ?-1:1; }
typedef tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>ordered_set;
typedef tree<pair<int, int>,null_type,less<pair<int, int>>,rb_tree_tag,tree_order_statistics_node_update> ordered_setpair;
typedef long long  ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<string> vs;
typedef vector<pair<int,int> > vii;
typedef map<int, int> mii;
typedef map<string, int> msi;
typedef pair<int, int> pii;
#define mii map <int, int>
#define mll map <ll, ll>
#define pii pair <int, int>
#define pll pair <ll, ll>
#define vi vector <int>
#define vd vector <double>
#define vll vector <ll>
#define sll set <ll>
#define spii set <pii>
#define vpii vector <pair <int,int> >
#define vpll vector <pair <long long,long long> >
#define vvi vector <vector <int> >
#define vvpii vector <vector <pii > >
#define sfi1(v) scanf("%d",&v)
#define sfi2(v1,v2) scanf("%d %d",&v1,&v2)
#define sfi3(v1,v2,v3) scanf("%d %d %d",&v1,&v2,&v3)
#define sfll1(v) scanf("%I64d",&v);
#define sfll2(v1,v2) scanf("%I64d %I64d",&v1,&v2)
#define sfll3(v1,v2,v3) scanf("%I64d %I64d %I64d",&v1,&v2,&v3)
#define min3(a,b,c)     min(a,min(b,c))
#define max3(a,b,c)     max(a,max(b,c))
#define min4(a,b,c,d)   min(a,min(b,min(c,d)))
#define max4(a,b,c,d)   max(a,max(b,max(c,d)))
#define el	'\n'
#define lp(i,n) for(int i = 0;i < int(n);i++)
#define lp1(i,n) for(int i = 1;i <= int(n);i++)
#define rlp(i, n) for (int i = (n) - 1; i >= 0; i--)
#define rng(i,a,b) for(int i = int(a);i <= int(b);i++)
#define mp(x,y)  	make_pair((x),(y))
#define pb(x)    	push_back((x))
#define all(v)  	((v).begin()),((v).end())
#define sz(x)  		((int) (x).size())
#define bits(a) 	__builtin_popcountll(a)
#define fr first
#define sc second
#define pii pair<int, int>
#define sortva(v) sort(all(v))
#define sortvd(v) sort(v.rbegin(),v.rend())
#define sortaa(a,n) sort(a,a+n)
#define sortad(a,n) sort(a,a+n),reverse(a,a+n)
#define SS stringstream
#define ll long long
#define clr(x, y) memset(x, y, sizeof(x))
#define foreach(it,x) for(__typeof__((x).begin()) it = (x).begin(); it != (x).end(); ++it)
#define read freopen("input.in", "rt", stdin);
#define write freopen("output.in", "wt", stdout);
#define fastIO cout << fixed << setprecision(0), ios::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
const int key = 37;
const int key2 = 59;
int dx[] = { 0, 0, 1, -1, 1, -1, 1, -1 };
int dy[] = { 1, -1, 0, 0, -1, 1, 1, -1 };
int kx[] = { 2, 2, 1, -1, -2, -2, 1, -1 };
int ky[] = { 1, -1, 2, 2, 1, -1, -2, -2 };
ll gcd(ll a, ll b){if (a == 0)return b;return gcd(b % a, a);}
ll lcm(ll a, ll b) { return (a / gcd(a, b)) * b; }

int const N = 5e5+9, mod = 998244353 ,  oo = 2e9+7;

//------------------------------------------------------------------------------------

set<pii>s;
int n,nofships,len;
bool ok (int nofships,int total){
return ((ll)nofships*(ll)len)+(ll)(nofships-1)<=(ll)total;
}

int get(int l,int r){

int len=r-l+1;
int lo=0,rr=4e5,med;
while(lo<rr){
	med=(lo+rr+1)>>1;
	if (ok(med,len))lo=med;
	else rr=med-1;
}
return lo;

}
int main()
{
	cin>>n>>nofships>>len;
	int y;
	cin>>y;
	s.insert(mp(1,n));
	int sum=get(1,n);
	for (int i=1;i<=y;i++){
		int x;
		cin>>x;
		auto it=s.upper_bound(mp(x,0));
		pii t=*--it;
		s.erase(it);
if (t.fr<=x-1	)s.insert(mp(t.fr,x-1));
	if (x+1<=t.sc	)	s.insert(mp(x+1,t.sc));
		sum-=get(t.fr,t.sc);
		sum+=get(t.fr,x-1);
		sum+=get(x+1,t.sc);
		if (sum<nofships)return cout<< i,0;
	}
	cout<< -1;

/*
*/
return 0;
}