#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, m, k, x, y;
  cin >> n >> m >> k >> x >> y;
  if (k < n * m) {
    cout << 1 << " " << 0 << " ";
    int r = k / m, f = k % m;
    if ((y <= f && r + 1 == x) || r >= x)
      cout << 1 << endl;
    else
      cout << 0 << endl;
    return 0;
  } else if (k == n * m) {
    cout << 1 << " " << 1 << " " << 1 << endl;
    return 0;
  }
  if (n == 1) {
    long long ma = k / m + 1;
    if (k % m == 0) ma--;
    cout << ma << " " << k / m << " ";
    if (k % m >= y)
      cout << ma << endl;
    else
      cout << k / m << endl;
    return 0;
  }
  if (n == 2) {
    long long mas = k / (2 * m), mas1 = k % (2 * m);
    long long max1 = mas, min1 = mas, ser1 = mas;
    if (mas1 != 0) {
      max1++;
      int mas22 = mas1 % m;
      if (mas1 > m) {
        if (x == 1 || (x == 2 && y <= mas22)) ser1++;
      } else {
        if (x == 1 && y <= mas22) ser1++;
      }
    }
    cout << max1 << " " << min1 << " " << ser1 << endl;
    return 0;
  }
  long long x1 = k / (2 * (n - 1) * m), x2 = k % (2 * (n - 1) * m);
  long long maxi, mini, ser;
  maxi = 2 * x1, mini = x1;
  bool bot = 0;
  if (x == 1 || x == n)
    ser = x1;
  else
    ser = x1 * 2;
  if (x2 < n * m) {
    long long r1 = x2 / m, r2 = x2 % m;
    if (r1 >= x || (r1 + 1 == x && y <= r2)) ser++;
    if (r1 > 1 || (r1 == 1 && r2 > 0)) maxi++;
  } else if (x2 >= n * m)
    maxi++, mini++, ser++;
  x2 = x2 - n * m;
  bool bo = 0, b1 = 0;
  long long x3 = 0;
  if (x2 > 0) {
    x3 = x2;
    for (int i = n - 1; i > 0; i--) {
      for (int j = 1; j <= m; j++) {
        if (x == i && y == j) ser++;
        x2--;
        if (x2 == 0) {
          bo = 1;
          break;
        }
      }
      if (bo) break;
    }
  }
  if (bo) maxi++;
  cout << maxi << " " << mini << " " << ser << endl;
  return 0;
}
