#include <bits/stdc++.h>
using namespace std;
template <typename T>
T next_int() {
  T x = 0, p = 1;
  char ch;
  do {
    ch = getchar();
  } while (ch <= ' ');
  if (ch == '-') {
    p = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    x = x * 10 + (ch - '0');
    ch = getchar();
  }
  return x * p;
}
const int max_n = (int)102;
const int max_int = (int)1e9 + 227 + 1;
const int mod = (int)1e9 + 7;
int main() {
  int n;
  cin >> n;
  int m;
  cin >> m;
  int k = n / m * m;
  k += m;
  cout << k << "\n";
}
