import java.io.BufferedReader import java.io.InputStream import java.io.InputStreamReader import java.lang.StringBuilder import java.util.* fun main(args: Array) { val sc = FastScanner(System.`in`) val a = sc.nextLong() val b = sc.nextLong() val x0 = sc.nextLong() val n = sc.nextLong() if (x0 % 2 == 0L) { println("%d %d".format(n / 2, 0)) } else { println("%d %d".format(0, n / 2)) } } class FastScanner(s: InputStream) { private var st = StringTokenizer("") private val br = BufferedReader(InputStreamReader(s)) fun next(): String { while (!st.hasMoreTokens()) st = StringTokenizer(br.readLine()) return st.nextToken() } fun nextInt() = next().toInt() fun nextLong() = next().toLong() fun nextLine() = br.readLine() fun nextDouble() = next().toDouble() fun ready() = br.ready() }