#include <bits/stdc++.h>
using namespace std;
int main() {
  unsigned long long n, k;
  cin >> n >> k;
  unsigned long long lo = 0, hi = min(n / 2, n / k + 1), mid;
  while (lo < hi) {
    mid = lo + (hi - lo + 1) / 2;
    if (mid + mid * k <= n / 2)
      lo = mid;
    else
      hi = mid - 1;
  }
  cout << lo << ' ' << lo * k << ' ' << n - (lo + lo * k);
  return 0;
}
