Birthday

题意翻译

# 题意描述 Ivan 在收集硬币。总共有 $N$ 种不同的纪念币,Ivan 有其中的 $K$ 种。Ivan 快要庆祝生日了,所以他的 $M$ 个朋友决定送他纪念币,要满足以下条件: - 每个人都要送一样多的硬币 - 每个硬币都必须是不同的 - 所有人送的纪念品至少有 $L$ 个是 Ivan 没有的。 但他的朋友不知道伊凡收藏的硬币中有哪些。他们不想花钱,所以他们想买最低数量的硬币,满足所有条件,不管伊凡的收藏量。 帮助他们找到这个**最小数量的硬币**,**或者告诉他们这是不可能的**。 ~~来自 十分地弱鸡(一个英语不及格的人)的翻译。翻译的不好见谅。~~ # 输入输出 ## 输入 输入仅一行,四个整数 $N,M,K,L$ $(1 \le K \le N \le 10^{18}\,;\,1 \le M,L \le 10^{18})$ 分别为纪念币总数 $N$,朋友数 $M$,Ivan 已收集的纪念币数 $K$,以及朋友们约定的至少要送给 Ivan 的纪念币总量 $L$ ## 输出 输出一个数 —— 朋友们**每人**至少要送的纪念币数 ,如果不可能做到他们约定的条件,输出 $-1$ 。

题目描述

Ivan is collecting coins. There are only $ N $ different collectible coins, Ivan has $ K $ of them. He will be celebrating his birthday soon, so all his $ M $ freinds decided to gift him coins. They all agreed to three terms: - Everyone must gift as many coins as others. - All coins given to Ivan must be different. - Not less than $ L $ coins from gifts altogether, must be new in Ivan's collection. But his friends don't know which coins have Ivan already got in his collection. They don't want to spend money so they want to buy minimum quantity of coins, that satisfy all terms, irrespective of the Ivan's collection. Help them to find this minimum number of coins or define it's not possible to meet all the terms.

输入输出格式

输入格式


The only line of input contains 4 integers $ N $ , $ M $ , $ K $ , $ L $ ( $ 1 \le K \le N \le 10^{18} $ ; $ 1 \le M, \,\, L \le 10^{18} $ ) — quantity of different coins, number of Ivan's friends, size of Ivan's collection and quantity of coins, that must be new in Ivan's collection.

输出格式


Print one number — minimal number of coins one friend can gift to satisfy all the conditions. If it is impossible to satisfy all three conditions print "-1" (without quotes).

输入输出样例

输入样例 #1

20 15 2 3

输出样例 #1

1

输入样例 #2

10 11 2 4

输出样例 #2

-1

说明

In the first test, one coin from each friend is enough, as he will be presented with 15 different coins and 13 of them will definitely be new. In the second test, Ivan has 11 friends, but there are only 10 different coins. So all friends can't present him different coins.