#include <bits/stdc++.h>
using namespace std;
template <typename T>
inline void gn(T &x) {
  x = 0;
  T f = 1;
  char ch = getchar();
  while (!isdigit(ch)) {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (isdigit(ch)) {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  x *= f;
}
template <typename T>
inline void gt(T x) {
  if (!x) return;
  gt(x / 10);
  putchar(x % 10 + '0');
}
const long long MAXN = 1e5 + 10;
long long t, n, m, ans;
long long MOD = 1e9 + 7, inf = 0x1f1f1f1f;
double eps = 1e-5;
long long u, v, w;
long long vis[111][111], R[111], C[111];
int main() {
  long long i, j, k, l, ca = 0;
  long long a, b, c, d, x, y;
  cin >> n >> m >> k >> x >> y;
  if (n == 1ll) {
    u = k / m + (k % m > 0ll);
    v = k / m;
    w = (k % m >= y ? u : v);
    cout << u << " " << v << " " << w << endl;
    return 0;
  }
  a = (n - 1ll) * m;
  b = k / a;
  if (n == 2ll) {
    a += m;
    v = k / a;
    u = k / a + (k % a > 0ll);
    l = k % a;
    for (i = 1ll; i <= n; i++) {
      for (j = 1ll; j <= m; j++) {
        if (l) {
          vis[i][j] = 1ll;
          l--;
        }
        if (l == 0ll) break;
      }
      if (l == 0ll) break;
    }
    w = v + vis[x][y];
    cout << u << " " << v << " " << w << endl;
    return 0;
  }
  if (b & 1ll) {
    if (k % a >= m)
      v = (b + 1ll) / 2ll;
    else
      v = b / 2ll;
    if (k % a > m)
      u = b + 1ll;
    else
      u = b;
    l = k % a;
    for (i = n; i >= 1ll; i--) {
      for (j = 1ll; j <= m; j++) {
        if (l) {
          vis[i][j] = 1ll;
          l--;
        }
        if (l == 0ll) break;
      }
      if (l == 0ll) break;
    }
    w = (x == 1ll ? ((b + 1ll) / 2ll) : (x == n ? (b / 2ll) : b)) + vis[x][y];
  } else {
    v = b / 2ll;
    u = max(b + ((k % a) > m), v + ((k % a) > 0ll));
    l = k % a;
    for (i = 1ll; i <= n; i++) {
      for (j = 1ll; j <= m; j++) {
        if (l) {
          vis[i][j] = 1ll;
          l--;
        }
        if (l == 0ll) break;
      }
      if (l == 0ll) break;
    }
    w = ((x == 1ll || x == n) ? (b / 2ll) : b) + vis[x][y];
  }
  cout << u << " " << v << " " << w << endl;
  return 0;
}
