克利切·皮尔森 @ 2018-10-10 16:35:06
using namespace std; int main() { int n,k,s=0,y; cin>>n>>k; y=n; for(int i=1;i<=n;i++) { if(n>k) { n=n-k; s++; } } cout<<y+s; return 0; }
by William_Chen_123 @ 2018-10-10 17:27:12
考虑一下当成数学题用公式吧
by peppaking8 @ 2018-11-12 18:09:24
希望更丰富的展现?使用Markdown
by ♂蒟·蒻 @ 2018-11-23 21:38:20
我也80,不知为啥
#include<bits/stdc++.h>
using namespace std;
int n,k;
int main()
{
cin>>n>>k;
cout<<n+n/k;
return 0;
}
by 零之执行人 @ 2018-12-16 19:48:24
#include<bits/stdc++.h>
using namespace std;
int main() {
int n,k,t;
cin>>n>>k;
cout<<n+(n-1)/(k-1);
return 0;
}
AC了
by D447H @ 2019-07-29 14:52:11
我也80.
#include<iostream>
#include<cstdio>
#include<cstring>
using namespace std;
int main()
{
int n,k,cue,tre;
cin>>n>>k;
cue=n;
if(n/k>=1) tre=n/k;
cue+=tre;
cout<<cue;
return 0;
}