Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
2286 邓小龙 14能吸多少根烟 C++ Wrong Answer 0 MS 260 KB 231 2023-12-23 16:45:51

Tests(0/10):


Code:

# include<iostream> using namespace std; int main(){ int a,b,c,d,z;//z存吸了多少根烟 cin>>a>>b; z=a; while(a>=b){ c=a/b; a=a%b+c; z=z+a; } cout<<z; return 0; }


Run Info:

------Input------
133 12
------Answer-----
145
------Your output-----
146