国产探花免费观看_亚洲丰满少妇自慰呻吟_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ā)表
主站蜘蛛池模板: 柯坪县| 堆龙德庆县| 株洲县| 宣汉县| 桦川县| 黑龙江省| 株洲市| 弥渡县| 巴林左旗| 秭归县| 黄平县| 富平县| 安塞县| 嘉祥县| 静海县| 甘肃省| 贺州市| 孟津县| 南京市| 仲巴县| 宜章县| 鹿泉市| 芜湖县| 当雄县| 兰州市| 温宿县| 榆中县| 云阳县| 六盘水市| 卓资县| 东辽县| 徐汇区| 佳木斯市| 淮南市| 若羌县| 乐平市| 南充市| 花莲市| 富阳市| 古田县| 突泉县|