#include <bits/stdc++.h>
using namespace std;
int main(){
// #ifndef TESTING
// freopen("input.txt", "r", stdin);
// freopen("output.txt", "w", stdout);
// #endif
long l, n;
cin >> l >> n;
int rolls = 1;
long sum = 0;
while(l % n != 0){
n -= l % n;
rolls++;
}
cout << rolls;
return 0;
}