#include <bits/stdc++.h>
using namespace std;
#pragma comment(linker, "/STACK:6408864")
template <typename T>
T abs(T a) {
  if (a < 0) return -a;
  return a;
}
template <typename T>
T sqr(T a) {
  return (a) * (a);
}
template <typename T>
int size(T& a) {
  return (int)((a).size());
}
void initf() {}
const double eps = 1e-8;
struct Pos {
  int x, y;
  void scan() { scanf("%d%d", &x, &y); }
  inline Pos(int x = 0, int y = 0) : x(x), y(y) {}
  inline Pos operator+(const Pos& o) const { return Pos(x + o.x, y + o.y); }
  inline Pos operator-(const Pos& o) const { return Pos(x - o.x, y - o.y); }
  void SetD() {
    this->x = (int)(this->x * 2);
    this->y = (int)(this->y * 2);
  }
  inline Pos getS(Pos a, Pos b) {
    Pos c = b - a;
    c.SetD();
    return Pos(c.x + a.x, c.y + a.y);
  }
};
Pos p[100001];
bool eq(double a, double b) {
  return (a - b < eps && b - a < eps || 1 - a / b < eps && a / b - 1 < eps);
}
bool eq1(double a, double b) { return (a - b < eps && b - a < eps); }
Pos mem[2000000];
int main() {
  initf();
  int n;
  long long id;
  cin >> n >> id;
  Pos m, m1, start;
  start.scan();
  mem[0] = start;
  for (int i = 0; i < n; ++i) p[i].scan();
  long long mod = 1;
  for (long long j = 1; j <= 2000000; ++j) {
    mem[j] = mem[j - 1].getS(mem[j - 1], p[(j - 1) % n]);
    if (id == j) {
      cout << mem[j].x << " " << mem[j].y;
      exit(0);
    }
    if (eq1(start.x, mem[j].x) && eq1(start.y, mem[j].y)) {
      mod = id % (long long)j;
      cout << mem[mod].x << " " << mem[mod].y;
      exit(0);
    }
  }
  printf("%0.lf %.0lf", start.x + eps, start.y + eps);
  return 0;
}
