Cod sursa(job #880134)

Utilizator thegamedragon24Shommy Theo thegamedragon24 Data 16 februarie 2013 13:00:21
Problema Next Scor 10
Compilator cpp Status done
Runda Arhiva de probleme Marime 0.23 kb
#include <iostream>
#include<fstream>
using namespace std;
int main()
{
    long long n,d,r=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;
}