Cod sursa(job #880131)
Utilizator | Data | 16 februarie 2013 12:57:18 | |
---|---|---|---|
Problema | Next | Scor | 0 |
Compilator | cpp | Status | done |
Runda | Arhiva de probleme | Marime | 0.23 kb |
#include <iostream>
#include<fstream>
using namespace std;
int main()
{
int n,d,r,ok=0;
ifstream f("next.in");
ofstream g("next.out");
f>>n>>d;
if(n%d==0) r=d;
else
r=(n/d+1)*d;
g<<r;
}