#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int64_t n, m, k, x, y;
  cin >> n >> m >> k >> x >> y;
  int64_t cycles = n + n - 2;
  if (n == 1) cycles = 1;
  int64_t students = cycles * m;
  int64_t max_questions = 0;
  int64_t min_questions = 0;
  max_questions += 2 * (k / students);
  min_questions += k / students;
  if (n <= 2) max_questions = min_questions;
  int64_t s;
  if (x == n || x == 1)
    s = min_questions;
  else
    s = max_questions;
  k %= students;
  if (k / m > n) {
    max_questions += 2;
    min_questions += 1;
  } else if (k / m == n) {
    max_questions += 1;
    min_questions += 1;
    if (k % m) max_questions += 1;
  } else if (k / m >= 1) {
    max_questions += 1;
  } else if (k / m == 0 && k % m && max_questions == min_questions) {
    max_questions += 1;
  } else if (n == 1 && k % m)
    max_questions++;
  if (x <= k / m) {
    s += 1;
    if (x != n && x != 1) {
      if (k / m > n) {
        if (x + 2 * (n - x) <= k / m) s += 1;
      }
    }
  }
  if (x == k / m + 1 || (x + 2 * (n - x)) == k / m + 1) {
    if (y <= k % m) s += 1;
  }
  cout << max_questions << " " << min_questions << " " << s;
}
