Cod sursa(job #196507)
| Utilizator | Data | 27 iunie 2008 00:48:50 | |
|---|---|---|---|
| Problema | Next | Scor | 10 |
| Compilator | cpp | Status | done |
| Runda | Arhiva de probleme | Marime | 0.18 kb |
#include <stdio.h>
long long n,d;
int main(){
freopen("next.in","r",stdin);
freopen("next.out","w",stdout);
scanf("%lld %lld",&n,&d);
printf("%lld",n+((d-(n%d))%d));
return 0;}