#include <bits/stdc++.h>
using namespace std;
const long double eps = 1e-10, inf = 1e18;
int n, t, q, p[200005], l[200005], r[200005];
long double ans = 0;
int read() {
  int f = 0, w = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') w = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    f = f * 10 + ch - '0';
    ch = getchar();
  }
  return f * w;
}
struct node {
  int pos;
  long double val;
  bool operator<(const node &a) const {
    return abs(val - a.val) > eps ? val < a.val : pos < a.pos;
  }
};
multiset<node> s, e;
long double calc(int pos, int x) {
  if (!~x) return inf;
  if (x >= l[pos]) return 0;
  return 1.0 * p[pos] * l[pos] / (x + l[pos]) / (x + 1 + l[pos]);
}
long double calc1(int pos) {
  return 1.0 * p[pos] * min(r[pos], l[pos]) / (min(r[pos], l[pos]) + l[pos]);
}
void add() {
  set<node>::iterator it = --s.end();
  ans += it->val;
  int p = it->pos;
  e.erase((node){p, calc(p, r[p] - 1)}), e.insert(*it);
  s.erase(it), s.insert((node){p, calc(p, ++r[p])});
}
void del() {
  set<node>::iterator it = e.begin();
  ans -= it->val;
  int p = it->pos;
  s.erase((node){p, calc(p, r[p])}), s.insert(*it);
  e.erase(it), e.insert((node){p, calc(p, (--r[p]) - 1)});
}
int main() {
  n = read(), t = read(), q = read();
  for (int i = 1; i <= n; i++) p[i] = read();
  for (int i = 1; i <= n; i++) l[i] = read();
  for (int i = 1; i <= n; i++) {
    s.insert((node){i, calc(i, 0)});
    e.insert((node){i, calc(i, -1)});
  }
  while (t--) add();
  for (int i = 1; i <= q; i++) {
    int opt = read(), pos = read();
    s.erase((node){pos, calc(pos, r[pos])}),
        e.erase((node){pos, calc(pos, r[pos] - 1)}), ans -= calc1(pos);
    l[pos] += (opt == 1) ? 1 : -1;
    s.insert((node){pos, calc(pos, r[pos])}),
        e.insert((node){pos, calc(pos, r[pos] - 1)}), ans += calc1(pos);
    while ((--s.end())->val > (e.begin()->val) + eps) del(), add();
    printf("%.10Lf\n", ans);
  }
  return 0;
}
