#include using namespace std; int main() { long long int budget, number,temp1,temp2,temp3,temp4,otosidama; cin >> budget >> number; temp1 = budget % 1000; temp2 = budget - temp1; temp3 = temp2 / 1000; temp4 = temp3/number; otosidama = temp4*1000; cout << otosidama; }