#include <bits/stdc++.h>
using namespace std;
long long n, m, x, y;
long long k;
long long Count(long long x, long long y) {
  long long ret = ((k + m - 1) / m + 2 * n - 3) / (2 * n - 2);
  long long r = ((k + m - 1) / m) % (2 * n - 2);
  if (r == 0) {
    r = 2 * n - 2;
  }
  long long c = k % m;
  if (c == 0) {
    c = m;
  }
  if (x == 1) {
    if (r == 1 && c < y) {
      --ret;
    }
  } else if (x == n) {
    if ((r < n) || (r == n && c < y)) {
      --ret;
    }
  } else {
    ret *= 2;
    if ((r < 2 * n - x) || (r == 2 * n - x && c < y)) {
      --ret;
    }
    if ((r < x) || (r == x && c < y)) {
      --ret;
    }
  }
  return ret;
}
long long Count12(long long x, long long y) {
  long long r = ((k + m - 1) / m) % n;
  if (r == 0) {
    r = n;
  }
  long long c = k % m;
  if (c == 0) {
    c = m;
  }
  long long ret = ((k + m - 1) / m + n - 1) / n;
  if ((r < x) || (r == x && c < y)) {
    --ret;
  }
  return ret;
}
int main() {
  while (scanf("%I64d%I64d%I64d%I64d%I64d", &n, &m, &k, &x, &y) != EOF) {
    if (n == 1 || n == 2) {
      printf("%I64d %I64d %I64d\n", Count12(1, 1), Count12(n, m),
             Count12(x, y));
    } else {
      long long Max =
          max(Count(1, 1), max(Count(2, 1), max(Count(n - 1, 1), Count(n, 1))));
      long long Min = Count(n, m);
      long long ans = Count(x, y);
      printf("%I64d %I64d %I64d\n", Max, Min, ans);
    }
  }
  return 0;
}
