#include <bits/stdc++.h>
using namespace std;
const int N = 3e5 + 7, M = 2e6;
const long long mod = 1e9 + 7;
inline int read() {
  int ret = 0;
  char ch = getchar();
  bool f = 1;
  for (; !isdigit(ch); ch = getchar()) f ^= !(ch ^ '-');
  for (; isdigit(ch); ch = getchar()) ret = (ret << 1) + (ret << 3) + ch - 48;
  return f ? ret : -ret;
}
long long gcd(long long a, long long b) { return b ? gcd(b, a % b) : a; }
long long ksm(long long a, long long b, long long mod) {
  int ans = 1;
  while (b) {
    if (b & 1) ans = (ans * a) % mod;
    a = (a * a) % mod;
    b >>= 1;
  }
  return ans;
}
long long inv2(long long a, long long mod) { return ksm(a, mod - 2, mod); }
long long xi[N], yi[N];
int main() {
  long long n;
  long long m;
  long long mx, my;
  scanf("%lld%lld", &n, &m);
  scanf("%lld%lld", &mx, &my);
  for (int i = 1; i <= n; i++) scanf("%lld%lld", &xi[i], &yi[i]);
  long long tmp = m / n;
  if (tmp % 2 == 0)
    tmp = m % n;
  else
    tmp = m % n + n;
  bool mark = true;
  long long ansx = 0, ansy = 0;
  for (int i = tmp; i >= 1; i--) {
    int zi;
    if (i > n)
      zi = i - n;
    else
      zi = i;
    if (mark) {
      ansx += 2 * xi[zi];
      mark = false;
      ansy += 2 * yi[zi];
    } else {
      ansx -= 2 * xi[zi];
      mark = true;
      ansy -= 2 * yi[zi];
    }
  }
  if (tmp % 2 == 0) {
    ansx += mx;
    ansy += my;
  } else {
    ansx -= mx;
    ansy -= my;
  }
  printf("%lld %lld\n", ansx, ansy);
  return 0;
}
