Problem: Chokudai loves eating so much. However, his doctor Akensho told him that he was overweight, so he finally decided to lose his weight.

Chokudai made a slimming plan of a $D$-day cycle. It is represented by $D$ integers $w_0, ..., w_{D-1}$. His weight is $S$ on the 0-th day of the plan and he aims to reduce it to $T$ ($S > T$). If his weight on the $i$-th day of the plan is $x$, it will be $x + w_{i\%D}$ on the $(i+1)$-th day. Note that $i\%D$ is the remainder obtained by dividing $i$ by $D$. If his weight successfully gets less than or equal to $T$, he will stop slimming immediately.

If his slimming plan takes too many days or even does not end forever, he should reconsider it.

Determine whether it ends or not, and report how many days it takes if it ends.



Input

The input consists of a single test case formatted as follows.


$S$ $T$ $D$
$w_0 ... w_{D-1}$


The first line consists of three integers $S$, $T$, $D$ ($1 \leq S, T, D \leq 100,000, S > T$). The second line consists of $D$ integers $w_0, ..., w_{D-1}$ ($-100,000 \leq w_i \leq 100,000$ for each $i$).

Output

If Chokudai's slimming plan ends on the $d$-th day, print $d$ in one line. If it never ends, print $-1$.

Examples

Input

65 60 3
-2 3 -4


Output

4


Input

65 60 3
-2 10 -3


Output

-1


Input

100000 1 1
-1


Output

99999


Input

60 59 1
-123


Output

1

Solution (in CPP):

Solution:
#define  _CRT_SECURE_NO_WARNINGS
#pragma comment (linker, "/STACK:526000000")

#include "bits/stdc++.h"

using namespace std;
typedef string::const_iterator State;
#define eps 1e-11L
#define MAX_MOD 1000000007LL
#define GYAKU 500000004LL

#define MOD 998244353LL
#define seg_size 262144*2LL
#define pb push_back
#define mp make_pair
typedef long long ll;
#define REP(a,b) for(long long (a) = 0;(a) < (b);++(a))
#define ALL(x) (x).begin(),(x).end()

unsigned long xor128() {
	static unsigned long x = 123456789, y = 362436069, z = 521288629, w = time(NULL);
	unsigned long t = (x ^ (x << 11));
	x = y; y = z; z = w;
	return (w = (w ^ (w >> 19)) ^ (t ^ (t >> 8)));
}

void init() {
	iostream::sync_with_stdio(false);
	cout << fixed << setprecision(20);
}

#define int ll

void solve(){
	int s, t, d;
	cin >> s >> t >> d;
	int req_loss = s - t;

	vector<int> inputs;
	int summing = 0;
	int going = 0;
	REP(i, d) {
		int a;
		cin >> a;
		a *= -1LL;
		summing += a;
		going = min(going, summing);
		inputs.push_back(a);
	}
	int ans = 0;
	REP(i, 30LL * d) {
		ans++;
		req_loss -= inputs[i % d];
		if (req_loss <= 0) {
			cout << ans << endl;
			return;
		}
	}
	ll bot = 1e5;
	ll top = -1;
	while (bot - top > 1) {
		ll mid = (top + bot) / 2LL;
		int now_val = req_loss - mid * summing;
		REP(j, d) {
			now_val -= inputs[j];
			if (now_val <= 0) break;
		}
		if (now_val <= 0) {
			bot = mid;
		}
		else {
			top = mid;
		}
	}
	ans += bot * d;
	req_loss -= bot * summing;
	REP(i, 30LL * d) {
		ans++;
		req_loss -= inputs[i % d];
		if (req_loss <= 0) {
			cout << ans << endl;
			return;
		}
	}
	cout << -1 << endl;
}

#undef int
int main() {
	init();
	solve();
}