国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 學院 > 開發(fā)設計 > 正文

cigarettes

2019-11-08 02:45:10
字體:
來源:轉載
供稿:網(wǎng)友

cigarettes

時間限制:3000 ms  |  內(nèi)存限制:65535 KB難度:2描述

Tom has many cigarettes. We hypothesized that he has n cigarettes and smokes them

one by one keeping all the butts. Out of k > 1 butts he can roll a new cigarette. Now,do you know how many cigarettes can Tom has?

輸入First input is a single line,it's n and stands for there are n testdata.then there are n lines ,each line contains two integer numbers giving the values of n and k.輸出For each line of input, output one integer number on a separate line giving the maximum number of cigarettes that Peter can have.樣例輸入
34 310 3100 5樣例輸出
514124


發(fā)表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發(fā)表
主站蜘蛛池模板: 湘西| 乃东县| 独山县| 灵山县| 磐安县| 谢通门县| 凭祥市| 千阳县| 关岭| 治县。| 溆浦县| 上虞市| 青龙| 淮阳县| 松溪县| 南雄市| 贺州市| 平山县| 库伦旗| 杭锦旗| 佛学| 离岛区| 乌什县| 定结县| 河源市| 醴陵市| 繁昌县| 九江市| 禄丰县| 兴化市| 唐山市| 沛县| 玉树县| 梧州市| 伊宁县| 嘉义市| 崇信县| 奇台县| 上栗县| 会理县| 婺源县|