/tmp/solutions/build/point_add_range_sum-main.cpp:
    1|       |#include <common.h>
    2|       |prelude;
    3|       |
    4|       |u64 a[500001];
    5|       |
    6|      1|int main() {
    7|      1|  rd rd;
    8|      1|  wt wt;
    9|      1|  int n = rd.uh();
   10|      1|  int q = rd.uh();
   11|   389k|  for (int i = 1; i <= n; ++i) a[i] = a[i - 1] + rd.uw();
                                        ^389k^389k
  ------------------
  |  Branch (11:19): [True: 100.00%, False: 0.00%]
  ------------------
   12|   389k|  for (int i = n; i >= 1; --i) a[i] -= a[i - (i & -i)];
                                        ^389k^389k
  ------------------
  |  Branch (12:19): [True: 100.00%, False: 0.00%]
  ------------------
   13|   410k|  while (q--) {
  ------------------
  |  Branch (13:10): [True: 100.00%, False: 0.00%]
  ------------------
   14|   410k|    let t = rd.u1();
   15|   410k|    if (t == 0) {
  ------------------
  |  Branch (15:9): [True: 49.88%, False: 50.12%]
  ------------------
   16|   204k|      int k = rd.uh() + 1;
   17|   204k|      int x = rd.uw();
   18|  2.15M|      for (; k <= n; k += k & -k) a[k] += x;
                                   ^1.95M       ^1.95M
  ------------------
  |  Branch (18:14): [True: 90.50%, False: 9.50%]
  ------------------
   19|   204k|    }
   20|   410k|    if (t == 1) {
  ------------------
  |  Branch (20:9): [True: 50.12%, False: 49.88%]
  ------------------
   21|   205k|      int l = rd.uh();
   22|   205k|      int r = rd.uh();
   23|   205k|      u64 ans = 0;
   24|  2.01M|      for (int k = l; k > 0; k -= k & -k) ans -= a[k];
                                           ^1.80M       ^1.80M
  ------------------
  |  Branch (24:23): [True: 89.77%, False: 10.23%]
  ------------------
   25|  2.16M|      for (int k = r; k > 0; k -= k & -k) ans += a[k];
                                           ^1.95M       ^1.95M
  ------------------
  |  Branch (25:23): [True: 90.49%, False: 9.51%]
  ------------------
   26|   205k|      wt.ud(ans);
   27|   205k|    }
   28|   410k|  }
   29|      1|  return 0;
   30|      1|}