#include <bits/stdc++.h>
using namespace std;
long long N, Q, a[200009], b[200009], c[200009], ne[200009], s = 0, T1 = 0,
                                                             T2 = 0;
bool I[600009];
priority_queue<pair<long long, long long>, vector<pair<long long, long long>>,
               greater<pair<long long, long long>>>
    posi;
priority_queue<pair<long long, long long>, vector<pair<long long, long long>>,
               less<pair<long long, long long>>>
    nega;
int main() {
  cin >> N >> Q;
  for (int i = 1; i <= 2 * N; i++) cin >> a[i];
  for (int i = 1; i <= 2 * N; i++) cin >> b[i];
  for (int i = 1; i <= 2 * N; i++) {
    c[i] = b[i] - a[i];
    s += a[i];
    I[i] = true;
    ne[i] = i;
    if (i >= 2 && i <= 2 * N - 1) {
      if (c[i] >= 0) {
        posi.push(make_pair(c[i], i));
        T1++;
        T2 += c[i];
      } else
        nega.push(make_pair(c[i], i));
    }
  }
  for (int i = 1; i <= Q; i++) {
    int p1, p2, p3;
    cin >> p1 >> p2 >> p3;
    long long to = p3 - p2;
    if (c[p1] >= 0) {
      T2 -= c[p1];
      T1--;
    }
    I[ne[p1]] = false;
    while (!posi.empty() && I[posi.top().second] == false) posi.pop();
    while (!nega.empty() && I[nega.top().second] == false) nega.pop();
    if (to >= 0) {
      posi.push(make_pair(to, 2 * N + i));
      T2 += to;
      T1++;
    } else
      nega.push(make_pair(to, 2 * N + i));
    s += (p2 - a[p1]);
    a[p1] = p2;
    b[p1] = p3;
    c[p1] = to;
    I[2 * N + i] = true;
    if (T1 % 2 == 0) {
      cout << T2 + s << endl;
    } else {
      long long V1 = T2 - posi.top().first;
      long long V2 = -(1LL << 60);
      if (!nega.empty()) V2 = T2 + nega.top().first;
      cout << max(V1, V2) + s << endl;
    }
  }
  return 0;
}
