criyle/codenet-compile-errors huggingface dataset:
Language: C++

#include <bits/stdc++.h>
using namespace std;

#pragma region lib_fenwick_tree
namespace lib {
  /*
    class FenwickTree
    usage: Fenwicktree f(100), FenwickTree<long long> f(100)
  */
  template <class T = int> class FenwickTree {
    public:
    FenwickTree() {}
    FenwickTree(int s) :
        size(s), data(s + 1, (T) 0) {}
    FenwickTree(const vector<T> &d) {
      size = d.size();
      data = vector<T>(size + 1, (T) 0);
      for (int i = 0; i < size; i++) add(i, d[i]);
    }

    /* index value must be 0-indexed */
    void add(int idx, const T &diff) {
      for (idx++; idx <= size; idx += (idx & -idx)) {
        data[idx] += diff;
      }
    }

    /* sum of the interval [0, idx] (inclusive, 0-indexed) */
    T sum(int idx) {
      T ret = 0;
      for (idx++; idx > 0; idx -= (idx & -idx)) {
        ret += data[idx];
      }
      return ret;
    }

    /* sum of the interval [l, r] (inclusive, 0-indexed) */
    T rangeSum(int l, int r) {
      return sum(r) - sum(l - 1);
    }

    private:
    int size;
    vector<T> data;
  };
}  // namespace lib
#pragma endregion

int main() {
  int N, Q;
  cin >> N >> Q;
  
  vector<int> a(N);
  for (int &in : a) cin >> in;
  
  lib::FenwickTree<long long> f(a);
  
  while (Q--) {
    int x, y, z;
    cin >> x >> y >> z;
    if (x == 0)
      f.add(y, z);
    else
      cout << f.rangeSum(y, z - 1) << endl;
  }
  
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:56:34: error: no matching function for call to 'lib::FenwickTree<long long int>::FenwickTree(std::vector<int>&)'
   56 |   lib::FenwickTree<long long> f(a);
      |                                  ^
a.cc:15:5: note: candidate: 'lib::FenwickTree<T>::FenwickTree(const std::vector<_Tp>&) [with T = long long int]'
   15 |     FenwickTree(const vector<T> &d) {
      |     ^~~~~~~~~~~
a.cc:15:34: note:   no known conversion for argument 1 from 'std::vector<int>' to 'const std::vector<long long int, std::allocator<long long int> >&'
   15 |     FenwickTree(const vector<T> &d) {
      |                 ~~~~~~~~~~~~~~~~~^
a.cc:13:5: note: candidate: 'lib::FenwickTree<T>::FenwickTree(int) [with T = long long int]'
   13 |     FenwickTree(int s) :
      |     ^~~~~~~~~~~
a.cc:13:21: note:   no known conversion for argument 1 from 'std::vector<int>' to 'int'
   13 |     FenwickTree(int s) :
      |                 ~~~~^
a.cc:12:5: note: candidate: 'lib::FenwickTree<T>::FenwickTree() [with T = long long int]'
   12 |     FenwickTree() {}
      |     ^~~~~~~~~~~
a.cc:12:5: note:   candidate expects 0 arguments, 1 provided
a.cc:10:34: note: candidate: 'lib::FenwickTree<long long int>::FenwickTree(const lib::FenwickTree<long long int>&)'
   10 |   template <class T = int> class FenwickTree {
      |                                  ^~~~~~~~~~~
a.cc:10:34: note:   no known conversion for argument 1 from 'std::vector<int>' to 'const lib::FenwickTree<long long int>&'
a.cc:10:34: note: candidate: 'lib::FenwickTree<long long int>::FenwickTree(lib::FenwickTree<long long int>&&)'
a.cc:10:34: note:   no known conversion for argument 1 from 'std::vector<int>' to 'lib::FenwickTree<long long int>&&'
Language: C++

#include <bits/stdc++.h>
using namespace std;

#pragma region lib_fenwick_tree
namespace lib {
  /*
    class FenwickTree
    usage: Fenwicktree f(100), FenwickTree<long long> f(100)
  */
  template <class T = int> class FenwickTree {
    public:
    FenwickTree() {}
    FenwickTree(int s) :
        size(s), data(s + 1, (T) 0) {}
    FenwickTree(const vector<T> &d) {
      size = d.size();
      data = vector<T>(size + 1, (T) 0);
      for (int i = 0; i < size; i++) add(i, d[i]);
    }

    /* index value must be 0-indexed */
    void add(int idx, const T &diff) {
      for (idx++; idx <= size; idx += (idx & -idx)) {
        data[idx] += diff;
      }
    }

    /* sum of the interval [0, idx] (inclusive, 0-indexed) */
    T sum(int idx) {
      T ret = 0;
      for (idx++; idx > 0; idx -= (idx & -idx)) {
        ret += data[idx];
      }
      return ret;
    }

    /* sum of the interval [l, r] (inclusive, 0-indexed) */
    T rangeSum(int l, int r) {
      return sum(r) - sum(l - 1);
    }

    private:
    int size;
    vector<T> data;
  };
}  // namespace lib
#pragma endregion

int main() {
  int N, Q;
  cin >> N >> Q;
  
  vector<int> a(N);
  for (int &in : a) cin >> in;
  
  lib::FenwickTree f(a);
  
  while (Q--) {
    int x, y, z;
    cin >> x >> y >> z;
    if (x == 0) {
      f.add(y, z);
    else
      cout << f.rangeSum(y, z) << endl;
  }
  
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:63:5: error: expected '}' before 'else'
   63 |     else
      |     ^~~~
a.cc:61:17: note: to match this '{'
   61 |     if (x == 0) {
      |                 ^
Language: C++

#include <bits/stdc++.h>
#include <boost/multiprecision/cpp_int.hpp>

//ACL

#include <atcoder/all>
using namespace atcoder;

//ACL END

#define int long long

#define override_rep(i, l, r, mes, ...) mes
#define rep1(i, n) for (int i = 0; i < n; i++)
#define rep2(i, l, r) for (int i = l; i < r; i++)
#define rep(...) override_rep(__VA_ARGS__, rep2, rep1)(__VA_ARGS__)

using namespace std;

using P = std::pair<int, int>;
using ll = long long;
using ld = double;

using bint = boost::multiprecision::cpp_int;


template<typename T, typename U>
std::istream& operator>>(std::istream& in, std::pair<T, U>& p) {
    in >> p.first >> p.second;
    return in;
}

const int MOD = 998244353;

// https://twitter.com/vane11ope ←フォローしましょう
// (ノ)>◡<(ヾ)ﾓﾁﾓﾁ
signed main(signed argc, char* argv[]) {
    std::cin.tie(nullptr);
    std::ios::sync_with_stdio(false);

    int n,q;
    cin>>n>>q;
    fenwick_tree<int> fw(n);
    rep(i,n){
        int in;
        cin>>in;
        fw.add(i,in);
    }
    rep(i,q){
        int t;
        cin>>t;
        if(t){
            int l,r;
            cin>>l>>r;
            cout<<fw.sum(l,r)<<endl;
        }
        else{
            int p,x;
            cin>>p>>x;
            fw.add(p,x);
        }
    }
}


Compiler output:
a.cc:2:10: fatal error: boost/multiprecision/cpp_int.hpp: No such file or directory
    2 | #include <boost/multiprecision/cpp_int.hpp>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <atcoder/fenwicktree>
#include <cstdio>

using namespace std;
using namespace atcoder;

int main() {
    int n, q;
    scanf("%d %d", &n, &q);

    fenwick_tree<long long> fw(n);
    for (int i = 0; i < n; i++) {
        int a;
        scanf("%d", &a);
        fw.add(i, a);
    }

    for (int i = 0; i < q; i++) {
        int t;
        scanf("%d", &t);
        if (t == 0) {
            int p, x;
            scanf("%d %d", &p, &x);
            fw.add(p, x);
        } else {
            int l, r;
            scanf("%d %d", &l, &r);
            printf("%lld\n", fw.sum(l, r));
        }
    }
}


Compiler output:
a.cc:1:10: fatal error: atcoder/fenwicktree: No such file or directory
    1 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C

#include <bits/stdc++.h>
typedef long long ll;
#define rep(i, n) for (ll i = 0, i##_len = (n); i < i##_len; ++i)
#define reps(i, n) for (ll i = 1, i##_len = (n); i <= i##_len; ++i)
#define rrep(i, n) for (ll i = ((ll)(n)-1); i >= 0; --i)
#define rreps(i, n) for (ll i = ((ll)(n)); i > 0; --i)
#define rep2(i, s, n) for (ll i = (s); i < (ll)(n); i++)
#define repc2(i, s, n) for (ll i = (s); i <= (ll)(n); i++)
#define inf 2e9
#define linf 9000000000000000000ll
#define all(v) v.begin(), v.end()
using namespace std;

template <typename T>
struct BIT {
    int n;
    vector<T> data;
    BIT(int n) : n(n + 1), data(n + 1, 0) {}
    void add(int i, T x) {
        for (int j = i; j < n; j += (j & -j)) {
            data[j] += x;
        }
    }
    T sum(int i) {
        T s(0);
        for (int j = i; j > 0; j -= (j & -j)) {
            s += data[j];
        }
        return s;
    }
    T sum(int l, int r) { return sum(r) - sum(l - 1); }
};

int n, q;

int main() {
    scanf("%d%d", &n, &q);
    BIT<ll> bit(n);
    reps(i, n) {
        ll a;
        scanf("%lld", &a);
        bit.add(i, a);
    }
    rep(i, q) {
        int c, a, b;
        scanf("%d%d%d", &c, &a, &b);
        a++, b++;
        if (c == 0) {
            bit.add(a, b);
        } else {
            printf("%lld\n", bit.sum(a, b - 1));
        }
    }
    return 0;
}

Compiler output:
main.c:1:10: fatal error: bits/stdc++.h: No such file or directory
    1 | #include <bits/stdc++.h>
      |          ^~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>

#include <atcoder/all>
using namespace atcoder;
using namespace std;
using ll = long long;
const ll INF = LONG_LONG_MAX / 2;
const ll mod = 1000000000 + 7;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};

int main() {
  ll N, Q;
  cin >> N >> Q;
  fenwick_tree<ll> fw(N);
  for (int i = 0; i < N; i++) {
    ll a;
    cin >> a;
    fw.add(i, a);
  }

  for (int i = 0; i < Q; i++) {
    ll p, q, r;
    cin >> p >> q >> r;
    if (p == 0) {
      fw.add(q, r);
    } else if (p == 1) {
      cout << fw.sum(q, r) << "\n";
    }
  }
}


Compiler output:
a.cc:3:10: fatal error: atcoder/all: No such file or directory
    3 | #include <atcoder/all>
      |          ^~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>

#include <atcoder/all>
using namespace atcoder;
using namespace std;
using ll = long long;
const ll INF = LONG_LONG_MAX / 2;
const ll mod = 1000000000 + 7;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};

int main() {
  int N, Q;
  cin >> N >> Q;
  fenwick_tree<int> fw(N);
  for (int i = 0; i < N; i++) {
    int a;
    cin >> a;
    fw.add(i, a);
  }

  for (int i = 0; i < Q; i++) {
    int p, q, r;
    cin >> p >> q >> r;
    if (p == 0) {
      fw.add(q, r);
    } else if (p == 1) {
      cout << fw.sum(q, r) << "\n";
    }
  }
}


Compiler output:
a.cc:3:10: fatal error: atcoder/all: No such file or directory
    3 | #include <atcoder/all>
      |          ^~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/all>
using namespace std;
using namespace atcoder;
#define rep2(i,m,n) for (int i = (m); i < (n); ++i)
#define rep(i,n) rep2(i,0,n)
#define debug(x) cerr << x << endl
typedef long long int ll;
typedef long double ld;
typedef pair<int, int> P;
template<typename T> struct V : vector<T> { using vector<T>::vector; };
V() -> V<int>;
V(size_t) -> V<int>;
template<typename T> V(size_t, T) -> V<T>;
template<typename T> vector<T> make_vec(size_t n, T a) { return vector<T>(n, a); }
template<typename... Ts> auto make_vec(size_t n, Ts... ts) { return vector<decltype(make_vec(ts...))>(n, make_vec(ts...)); }
template<typename T> ostream &operator<<(ostream &os, const vector<T> &v) { for (auto &e : v) os << e << ' '; return os; }
struct fast_ios { fast_ios(){ cin.tie(nullptr); ios::sync_with_stdio(false); cout << fixed << setprecision(20); }; } fast_ios_;
template<typename T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return true; } return false; }
template<typename T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return true; } return false; }
const int INF = 1<<30;
const ll LINF = 1LL<<61;
const ll MOD = 1000000007;

int main()
{
    int n, q;
    cin >> n >> q;
    fenwick_tree<ll> fw(n);
    rep(i,n)
    {
        int a;
        cin >> a;
        fw.add(i,a);
    }
    rep(i,q)
    {
        int t;
        cin >> t;
        if(t)
        {
            int l, r;
            cin >> l >> r;
            cout << fw.sum(l, r) << "\n";
        }
        else
        {
            int p, x;
            cin >> p >> x;
            fw.add(p, x);
        }
        
    }

    return 0;
}


Compiler output:
a.cc:2:10: fatal error: atcoder/all: No such file or directory
    2 | #include <atcoder/all>
      |          ^~~~~~~~~~~~~
compilation terminated.
Language: C++

#define _USE_MATH_DEFINES

#include <iostream>
#include <iomanip>
#include <string>
#include <vector>
#include <algorithm>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <cmath>
#include <intrin.h>
#include<atcoder/fenwicktree.hpp>
using namespace std;
using namespace atcoder;

typedef long long ll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
typedef tuple<ll, ll, ll> tl3;



const int BIG_NUM = 1e9;
const ll INF = 1000000000000000000;
//const ll MOD = 1e9 + 7;
const ll MOD = 998244353;



int main() {
	int n, q;
	cin >> n >> q;
	fenwick_tree<ll> fw(n);
	for (int i = 0; i < n; i++) {
		int a;
		cin >> a;
		fw.add(i, a);
	}

	for (int i = 0; i < q; i++) {
		int t;
		cin >> t;
		if (t) {
			int l, r;
			cin >> l >> r;
			cout << fw.sum(l, r) << endl;
		}
		else {
			int p, x;
			cin >> p >> x;
			fw.add(p, x);
		}
	}
}

Compiler output:
a.cc:13:10: fatal error: intrin.h: No such file or directory
   13 | #include <intrin.h>
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <map>
#include <set>
//#include <queue>
//#include <stack>
#include <cstring>
#include <cassert>

#include <atcoder/fenwicktree>

using namespace std;

#ifdef LOCAL_DEBUG
#include <local_debug.h>
#define DEBUG(...) DBG2::print(#__VA_ARGS__, __LINE__, __VA_ARGS__)
#else
#define DEBUG(...)
#endif

#define SZ(a) int((a).size())
#define REP(i,n) for(int i=0,_n=(n);i<_n;++i)
#define FOR(i,a,b) for(int i=(a),_b=(b);i<=_b;++i)

typedef long long llong;
typedef vector<int> VI;
typedef vector<VI> VVI;



int main(int argc, char* argv[]) {
   ios_base::sync_with_stdio(false); 
   cin.tie(nullptr);

   int N, Q;
   cin >> N >> Q;

   atcoder::fenwick_tree<llong> FT(N);
   REP(i, N) {
      int a;
      cin >> a;
      FT.add(i, a);
   }

   REP(q, Q) {
      int t;
      cin >> t;
      if (t == 0) {
         int p, x;
         cin >> p >> x;
         FT.add(p, x);
      }
      else {
         int L, R;
         cin >> L >> R;
         llong res = FT.sum(L, R);
         cout << res << '\n';
      }
   }

   return 0;
}


Compiler output:
a.cc:12:10: fatal error: atcoder/fenwicktree: No such file or directory
   12 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++


// #include <atcoder/all>
#include <atcoder/fenwicktree>
#include <bits/stdc++.h>
using namespace std;
using namespace atcoder;
typedef long long ll;
typedef pair<ll, ll> lpair;
const ll MOD = 1e9 + 7;
const ll INF = 1e18;
#define REP(i, m, n) for (ll i = (m); i < (n); i++)
#define rep(i, n) REP(i, 0, (n))

int main()
{
  cin.tie(0);
  ios::sync_with_stdio(false);

  int n, q;
  cin >> n >> q;
  fenwick_tree<ll> fw(n);

  rep(i,n)
  {
    ll a;
    cin >> a;
    fw.add(i, a);
  }

  rep(i,q)
  {
    ll t,p,x;
    cin >> t >> p >> x;
    if (t==0)
    {
      fw.add(p, x);
    }
    else
    {
      cout << fw.sum(p, x) << endl;
    }
  }
  
}

Compiler output:
a.cc:3:10: fatal error: atcoder/fenwicktree: No such file or directory
    3 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/fenwicktree>
using namespace std;
using ll = long long;

int main() {
    int N, Q; cin >> N >> Q;
    fenwick_tree<long long> bit(N+1);
    for (int i=1;i<=N;i++) {
        int a; cin >> a;
        bit.add(i, a);
    }
    for (int q=0; q<Q; q++) {
        int d, l, r; 
		cin >> d >> l >> r;
        if (d == 0) {
            bit.add(l+1, r);
        } else {
            cout << bit.sum(l+1, r+1) << "\n";
        }
    }
}

Compiler output:
a.cc:2:10: fatal error: atcoder/fenwicktree: No such file or directory
    2 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/fenwicktree>
using namespace std;
using ll = long long;

int main() {
    cin.tie(nullptr);
    int N, Q; cin >> N >> Q;
    fenwick_tree<ll> bit(N+1);
    for (int i=1;i<=N;i++) {
        int a; cin >> a;
        bit.add(i+1, a);
    }
    for (int q=0; q<Q; q++) {
        int d, l, r; 
		cin >> d >> l >> r;
        if (d == 0) {
            bit.add(l+1, r);
        } else {
            cout << bit.sum(l+1, r+1) << "\n";
        }
    }
}


Compiler output:
a.cc:2:10: fatal error: atcoder/fenwicktree: No such file or directory
    2 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include "atcoder/fenwicktree"
#include <cstdio>

using namespace std;
using namespace atcoder;

int main() {
    int n, q;
    scanf("%d %d", &n, &q);

    fenwick_tree<long long> fw(n);
    for (int i = 0; i < n; i++) {
        int a;
        scanf("%d", &a);
        fw.add(i, a);
    }

    for (int i = 0; i < q; i++) {
        int t;
        scanf("%d", &t);
        if (t == 0) {
            int p, x;
            scanf("%d %d", &p, &x);
            fw.add(p, x);
        } else {
            int l, r;
            scanf("%d %d", &l, &r);
            printf("%lld\n", fw.sum(l, r));
        }
    }
}


Compiler output:
a.cc:1:10: fatal error: atcoder/fenwicktree: No such file or directory
    1 | #include "atcoder/fenwicktree"
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/fenwicktree.hpp>


#define mp make_pair
#define eb emplace_back
#define ff first
#define ss second

using namespace std;

typedef long long ll;
typedef unsigned long long ull;

#ifdef ONPC
mt19937 rnd(228);
#else
mt19937 rnd(chrono::steady_clock::now().time_since_epoch().count());
#endif


const int MAXN = 100;
//#define int long long
const int INF = 1e9;

void solve(){
  int n, q;
  cin >> n >> q;
  int c, u, v;
  atcoder::fenwick_tree<ll> f(n + 1);
  for (int i = 0; i < q; i++){
    cin >> c >> u >> v;
    if (!c) f.add(u, v);
    else {
      cout << f.sum(u, v) << '\n';
    }
  }
}

signed main()
{
    #ifdef FILEIO
      freopen("input.txt", "r", stdin);
      freopen("output.txt", "w", stdout);
    #endif

    ios_base::sync_with_stdio(0);
    cin.tie(0);

    solve();

    return 0;
}


Compiler output:
a.cc:2:10: fatal error: atcoder/fenwicktree.hpp: No such file or directory
    2 | #include <atcoder/fenwicktree.hpp>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <iostream>
#include <vector>
#include <algorithm>
#include <iomanip>
#include <string>
#include <stack>
#include <queue>
#include <map>
#include <set>
#include <tuple>
#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <climits>
#include <cassert>
#include <cstdint>
#include <cctype>
#include <numeric>
#include <bitset>
#include <functional>
#include <atcoder/fenwicktree>

using namespace std;

using ll =  long long;
using Pll = pair<ll, ll>;
using Pii = pair<int, int>;

constexpr int INF = 1 << 30;
constexpr ll LINF = 1LL << 60;
constexpr ll MOD = 1000000007;
constexpr long double EPS = 1e-10;
constexpr int dyx[4][2] = {
    { 0, 1}, {-1, 0}, {0,-1}, {1, 0}
};
int main() {
    ios::sync_with_stdio(false); cin.tie(nullptr);
    int n, q, a, b;
    cin >> n >> q;
    atcoder::fenwick_tree<ll> fw(n+1);
    for(int i=0;i<q;++i) {
        cin >> a >> b >> c;
        if(a == 0) {
            fw.add(b, c);
        } else {
            cout << d.sum(b, c) << endl;
        }
    }
}

Compiler output:
a.cc:21:10: fatal error: atcoder/fenwicktree: No such file or directory
   21 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <iostream>
#include <vector>
#include <algorithm>
#include <iomanip>
#include <string>
#include <stack>
#include <queue>
#include <map>
#include <set>
#include <tuple>
#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <climits>
#include <cassert>
#include <cstdint>
#include <cctype>
#include <numeric>
#include <bitset>
#include <functional>
#include <atcoder/fenwicktree>

using namespace std;

using ll =  long long;
using Pll = pair<ll, ll>;
using Pii = pair<int, int>;

constexpr int INF = 1 << 30;
constexpr ll LINF = 1LL << 60;
constexpr ll MOD = 1000000007;
constexpr long double EPS = 1e-10;
constexpr int dyx[4][2] = {
    { 0, 1}, {-1, 0}, {0,-1}, {1, 0}
};
int main() {
    ios::sync_with_stdio(false); cin.tie(nullptr);
    int n, q, a, b; ll c;
    cin >> n >> q;
    atcoder::fenwicktree<ll> fw(n+1);
    for(int i=0;i<q;++i) {
        cin >> a >> b >> c;
        if(a == 0) {
            fw.add(b, c);
        } else {
            cout << d.sum(b, c) << endl;
        }
    }
}

Compiler output:
a.cc:21:10: fatal error: atcoder/fenwicktree: No such file or directory
   21 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/all>
using namespace std;
using namespace atcoder;

int main(){
  long long N,Q;
  cin >> N >> Q;
  fenwick_tree<long long> A(N);
  for(int i=0;i<N;i++){
    long long a;
    cin >> a;
    A.add(i,a);
  }
  
  for(int i=0;i<Q;i++){
    long long q,x,y;
    cin >> q >> x >> y;
    
    if(q==0){
      A.add(x,y);
    }
    if(q==1){
      cout << A.sum(x,y) << endl;
    }
  }
  return 0;
}

Compiler output:
a.cc:2:10: fatal error: atcoder/all: No such file or directory
    2 | #include <atcoder/all>
      |          ^~~~~~~~~~~~~
compilation terminated.
Language: Java

import java.util.*;

public class Main {

    Scanner sc = new Scanner(System.in);

    public static void main(String[] args) {
        new Main().run();
    }

    void run() {

        int n = sc.nextInt();
        int q = sc.nextInt();
        long[] a = new long[n];
        BIT bit = new BIT(n);
        for (int i=0; i<n; i++) a[i] = sc.nextLong();
        for (int i=0; i<n; i++) bit.add(i+1, a[i]);
        StringBuilder sb = new StringBuilder();
        for (int i=0; i<q; i++) {
            int t = sc.nextInt();
            if (t == 0) {
                int p = sc.nextInt();
                int x = sc.nextInt();
                bit.add(p+1, x);
            } else {
                int l = sc.nextInt();
                int r = sc.nextInt();
                int diff = bit.sum(r) - bit.sum(l);
                sb.append(diff + "\n");
            }
        }

        System.out.print(sb.toString());

    }

    class BIT {
        int n;
        long[] arr;

        public BIT(int n) {
            this.n = n;
            arr = new long[n + 1];
        }

        void add(int idx, long val) {
            for (int i = idx; i <= n; i += i & -i) {
//                System.out.print(i);
                arr[i] += val;
            }
        }

        long sum(int idx) {
            long sum = 0;
            for (int i = idx; i > 0; i -= i & -i) {
                sum += arr[i];
            }
            return sum;
        }
    }


}



Compiler output:
Main.java:29: error: incompatible types: possible lossy conversion from long to int
                int diff = bit.sum(r) - bit.sum(l);
                                      ^
1 error
Language: C++

#include <iostream>
#include <string>
#include <cmath>
#include<algorithm>
#include<stack>
#include<queue>
#include<map>
#include<set>
#include<iomanip>
#define _USE_MATH_DEFINES
#include <math.h>
#include <functional>
#include<complex>
#include<cassert>
using namespace std;
#include<atcoder/all>
using namespace atcoder;


#define rep(i,x) for(ll i=0;i<x;i++)
#define repn(i,x) for(ll i=1;i<=x;i++)

typedef long long ll;
const ll INF = 1e17;
const ll MOD = 998244353;
const ll MAX = 4000001;
const long double eps = 1E-14;

ll max(ll a, ll b) {
	if (a > b) { return a; }
	return b;
}

ll min(ll a, ll b) {
	if (a > b) { return b; }
	return a;
}

ll gcd(ll a, ll b) {
	if (b == 0) { return a; }
	if (a < b) { return gcd(b, a); }
	return gcd(b, a % b);
}

ll lcm(ll a, ll b) {
	return a / gcd(a, b) * b;
}

struct edge {
	ll ind;
	ll fr;
	ll to;
	ll d;
};

using mint = modint998244353;

typedef vector<ll> vll;
typedef vector<vector<ll>> vvll;
typedef vector<vector<vector<ll>>> vvvll;

typedef vector<mint> vmint;
typedef vector<vector<mint>> vvmint;
typedef vector<vector<vector<mint>>> vvvmint;

/////////////////////////////////////

int main() {
	ll N, Q;
	cin >> N >> Q;

	vll a(N);
	rep(i, N)cin >> a[i];

	fenwick_tree<ll> fw(N);
	rep(i, N)fw.add(i, a[i]);

	rep(q, Q) {
		ll t;
		cin >> t;

		if(t==0){
			ll p, x;
			cin >> p >> x;
			fw.add(p, x);
		}
		else {
			ll l, r;
			cin >> l >> r;
			cout << fw.sum(l, r) << endl;
		}
	}
}


Compiler output:
a.cc:16:9: fatal error: atcoder/all: No such file or directory
   16 | #include<atcoder/all>
      |         ^~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/all>
using namespace std;
using namespace atcoder;
using ll = long long;
using ull = unsigned long long;
using ld = long double;
using pii = pair<int, int>;
using piii = pair<pii, int>;
using pll = pair<ll, ll>;
using pli = pair<ll, int>;
using pil = pair<int, ll>;
using uint = unsigned int;
template <typename T>
using Graph = vector<vector<T>>;
const int MOD = 1e9 + 7;
const ld PI = acosl(-1);

int main() {
    cin.tie(0);
    ios::sync_with_stdio(false);

    int N, Q;
    cin >> N >> Q;

    fenwick_tree<ll> fw(N);
    for (int i = 0; i < N; ++i) {
        int a;
        cin >> a;
        fw.add(i, a);
    }

    for (int i = 0; i < Q; ++i) {
        int com, a, b;
        cin >> com >> a >> b;
        if (com == 0)
            fw.add(a, b);
        else
            cout << fw.sum(a, b) << '\n';
    }

    return 0;
}


Compiler output:
a.cc:2:10: fatal error: atcoder/all: No such file or directory
    2 | #include <atcoder/all>
      |          ^~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/segtree>
using namespace std;
using namespace atcoder;
#define int long long
#define ld long double
#define ll long long
#define P pair<int,int>
#define fi first
#define se second
#define rep(i,n) for(int i=0;i<n;i++)
#define all(v) v.begin(),v.end()
#define pb push_back
#define eb emplace_back
template<class T>void chmax(T &a,T b){if(a<b)a=b;}
template<class T>void chmin(T &a,T b){if(a>b)a=b;}
constexpr int INF=1000000000000000000;
constexpr int mod=1000000007;
constexpr double eps=1e-8;
const double pi=acos(-1);
int dx[]={0,1,0,-1},dy[]={1,0,-1,0};
int Random(int mi,int ma){
    random_device rnd;
    mt19937 mt(rnd());//32bit
    //[mi,ma]
    uniform_int_distribution<int>engine(mi,ma);
    return engine(mt);
}
int gcd(int a,int b){
    if(b==0)return a;
    return gcd(b,a%b);
}
int lcm(int a,int b){
    return a/gcd(a,b)*b;
}
bool prime(int a){
    if(a==1)return false;
    for(int i=2;i*i<=a;i++){
        if(a%i==0)return false;
    }
    return true;
}
int modpow(int a,int b){
    if(b==0)return 1;
    if(b%2)return modpow(a,b-1)*a%mod;
    int memo=modpow(a,b/2);
    return memo*memo%mod;
}
vector<int>kaijo,invkaijo;
void init_fact(int n){
    kaijo.resize(n+1);
    invkaijo.resize(n+1);
    kaijo[0]=1;
    for(int i=1;i<=n;i++){
        kaijo[i]=kaijo[i-1]*i;
        kaijo[i]%=mod;
    }
    rep(i,n+1)invkaijo[i]=modpow(kaijo[i],mod-2);
}
int comb(int a,int b){
    if(a<b)return 0;
    if(a<0||b<0)return 0;
    return kaijo[a]*invkaijo[a-b]%mod*invkaijo[b]%mod;
}
int inv(int x){
    x=modpow(x,mod-2);
    return x;
}
signed main(){
    cin.tie(0);ios::sync_with_stdio(false);
    int n;
    cin>>n;
    cout<<n*n<<endl;
    return 0;
}


Compiler output:
a.cc:2:10: fatal error: atcoder/segtree: No such file or directory
    2 | #include <atcoder/segtree>
      |          ^~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <atcoder/fenwicktree>
#include "bits/stdc++.h"
using namespace std;
using namespace atcoder;

const int N=2e5+20;

int n,q,t,u,v;

int main()
{
	scanf("%d%d",&n,&q);
	auto dsa=fenwick_tree<long long>(n);
  	for(int i=0;i<n;i++) scanf("%d",&u),dsa.add(i,u);

	while(q--)
	{
		scanf("%d%d%d",&t,&u,&v);
		if(t==0) dsa.add(u,v);
		else printf("%d\n",dsa.sum(u,v));
	}
}

Compiler output:
a.cc:1:10: fatal error: atcoder/fenwicktree: No such file or directory
    1 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include<bits/stdc++.h>
#include<atcoder/fenwick_tree>
using namespace std;
using namespace atcoder;
int main(){
  int n, m;
  cin >> n >> m;
  fenwick_tree<long long> fn(n);
  for(int i=0; i<n; i++){
      int a;
      cin >> a;
      fn.add(i, a);
    }
  while(m--){
    int t, a, b;
    cin >> t >> a >> b;
    if(t == 0){
      fn.add(a, b);
    }else{
      cout << fn.sum(a, b) << "\n";
    }
  }
  return 0;
}


Compiler output:
a.cc:2:9: fatal error: atcoder/fenwick_tree: No such file or directory
    2 | #include<atcoder/fenwick_tree>
      |         ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include<bits/stdc++.h>
#include<atcoder/fenwick_tree>
using namespace std;
using namespace atcoder;
int main(){
  int n, m;
  cin >> n >> m;
  while(m--){
    int t, a, b;
    fenwick_tree<long long int> fn(n);
    for(int i=0; i<n; i++){
      int a;
      cin >> a;
      fn.add(i, a);
    }
    cin >> t >> a >> b;
    if(t == 0){
      fn.add(a, b);
    }else{
      cout << fn.sum(a, b);
    }
    cout << "\n";
  }
  return 0;
}

Compiler output:
a.cc:2:9: fatal error: atcoder/fenwick_tree: No such file or directory
    2 | #include<atcoder/fenwick_tree>
      |         ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define w(x) int x;cin>>x;while(x--)
#define ll long long
#define pb push_back
#define fast ios_base::sync_with_stdio(false);cin.tie(NULL)
#define vi vector<int>
#define fr(a,b) for(int i=a;i<=b;i++)
#define inf 1e18
#define mod 1000000007
ll BIT[500005];
ll n;
ll answer(ll i)
{
	ll sum=0;
	while(i>0)
	{
		sum+=BIT[i];
		i=i-(i&(-i));
	}
	return sum;
}
void update(int i,ll val)
{
	while(i<=n)
	{
		BIT[i]+=val;
		i=i+(i&(-i));
	}
}
int main()
{   
#ifndef ONLINE_JUDGE
	freopen("input.txt", "r",stdin);
	freopen("output.txt", "w",stdout);
#endif
	fast;
	ll q;
	cin>>n>>q;
	ll a[n+2];
	for(int i=1;i<=n;i++){
		cin>>a[i];
		update(i,a[i]);
	}
	while(q--)
	{
		int k;
		cin>>k;
		if(k==0)
		{
			ll i,val;
			cin>>i>>val;
			update(i+1,val);
		}
		if(k==1)
		{
			int l,r;
			cin>>l>>r;
			cout<<answer(r)-answer(l)<<"\n";
		}
	}

}#include <bits/stdc++.h>
using namespace std;
#define w(x) int x;cin>>x;while(x--)
#define ll long long
#define pb push_back
#define fast ios_base::sync_with_stdio(false);cin.tie(NULL)
#define vi vector<int>
#define fr(a,b) for(int i=a;i<=b;i++)
#define inf 1e18
#define mod 1000000007
ll BIT[500005];
ll n;
ll answer(ll i)
{
	ll sum=0;
	while(i>0)
	{
		sum+=BIT[i];
		i=i-(i&(-i));
	}
	return sum;
}
void update(int i,ll val)
{
	while(i<=n)
	{
		BIT[i]+=val;
		i=i+(i&(-i));
	}
}
int main()
{   
/*#ifndef ONLINE_JUDGE
	freopen("input.txt", "r",stdin);
	freopen("output.txt", "w",stdout);
#endif*/
	fast;
	ll q;
	cin>>n>>q;
	ll a[n+2];
	for(int i=1;i<=n;i++){
		cin>>a[i];
		update(i,a[i]);
	}
	while(q--)
	{
		int k;
		cin>>k;
		if(k==0)
		{
			ll i,val;
			cin>>i>>val;
			update(i+1,val);
		}
		if(k==1)
		{
			ll l,r;
			cin>>l>>r;
			cout<<answer(r)-answer(l)<<"\n";
		}
	}

}

Compiler output:
a.cc:63:2: error: stray '#' in program
   63 | }#include <bits/stdc++.h>
      |  ^
a.cc:63:3: error: 'include' does not name a type
   63 | }#include <bits/stdc++.h>
      |   ^~~~~~~
a.cc:73:4: error: redefinition of 'long long int BIT [500005]'
   73 | ll BIT[500005];
      |    ^~~
a.cc:11:4: note: 'long long int BIT [500005]' previously declared here
   11 | ll BIT[500005];
      |    ^~~
a.cc:74:4: error: redefinition of 'long long int n'
   74 | ll n;
      |    ^
a.cc:12:4: note: 'long long int n' previously declared here
   12 | ll n;
      |    ^
a.cc:75:4: error: redefinition of 'long long int answer(long long int)'
   75 | ll answer(ll i)
      |    ^~~~~~
a.cc:13:4: note: 'long long int answer(long long int)' previously defined here
   13 | ll answer(ll i)
      |    ^~~~~~
a.cc:85:6: error: redefinition of 'void update(int, long long int)'
   85 | void update(int i,ll val)
      |      ^~~~~~
a.cc:23:6: note: 'void update(int, long long int)' previously defined here
   23 | void update(int i,ll val)
      |      ^~~~~~
a.cc:93:5: error: redefinition of 'int main()'
   93 | int main()
      |     ^~~~
a.cc:31:5: note: 'int main()' previously defined here
   31 | int main()
      |     ^~~~
Language: C++

// 2020-09-16 00:25:29
// clang-format off
#include <bits/stdc++.h>
#ifdef LOCAL
#include "lib/debug.hpp"
#else
#define debug(...) 1
#endif
#define ALL(a) (a).begin(), (a).end()
#define RALL(a) (a).rbegin(), (a).rend()
#define rep(i, n) REP(i, 0, (n))
#define repc(i, n) REPC(i, 0, (n))
#define REP(i, n, m) for (int i = (int)(n); i < (int)(m); i++)
#define REPC(i, n, m) for (int i = (int)(n); i <= (int)(m); i++)
#define REPCM(i, n, m) for (int i = (int)(n); i >= (int)(m); i--)
using namespace std;
using ll = long long;
using ld = long double;
using pr = pair<ll, ll>;
using vll = vector<ll>;
using vpr = vector<pr>;
using P = pair<int, int>;
template<class T> inline bool chmin(T& a, const T& b) { if (a > b) { a = b; return true; } else return false; }
template<class T> inline bool chmax(T& a, const T& b) { if (a < b) { a = b; return true; } else return false; }
// #include <atcoder/convolution>
// #include <atcoder/dsu>
#include <atcoder/fenwicktree>
// #include <atcoder/lazysegtree>
// #include <atcoder/math>
// #include <atcoder/maxflow>
// #include <atcoder/mincostflow>
// #include <atcoder/modint>
// #include <atcoder/scc>
// #include <atcoder/segtree>
// #include <atcoder/string>
// #include <atcoder/twosat>
// #include <atcoder/all>
using namespace atcoder;

// clang-format on
void answer() {
  int n, q;
  cin >> n >> q;
  fenwick_tree<ll> fw(n);
  rep(i, n) {
    ll a;
    cin >> a;
    fw.add(i, a);
  }
  rep(i, q) {
    int c;
    cin >> c;
    if (c == 0) {
      ll p, x;
      cin >> p >> x;
      fw.add(p, x);
    } else {
      int l, r;
      cin >> l >> r;
      cout << fw.sum(l, r) << '\n';
    }
  }
}

int main() {
  std::ios::sync_with_stdio(false);
  std::cin.tie(0);
  answer();
  return 0;
}

Compiler output:
a.cc:27:10: fatal error: atcoder/fenwicktree: No such file or directory
   27 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/fenwicktree>
#define repr(i,a,b) for(int i=a;i<b;i++)
#define rep(i,n) for(int i=0;i<n;i++)
#define reprrev(i,a,b) for(int i=b-1;i>=a;i--) // [a, b)
#define reprev(i,n) reprrev(i,0,n)
//#define _GLIBCXX_DEBUG

using ll = long long;
using ull = unsigned long long;
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return true; } return false; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return true; } return false; }
const ll mod = 1e9+7;
void chmod(ll &M){
  if(M >= mod) M %= mod;
  else if(M < 0){
     M += (abs(M)/mod + 1)*mod;
    M %= mod;
}
}
ll modpow(ll x, ll n){
   if(n==0) return 1;
  ll res=modpow(x, n/2);
 if(n%2==0) return res*res%mod;
else return res*res%mod*x%mod;
}
int getl(int i, int N) { return i==0? N-1:i-1; };
int getr(int i, int N) { return i==N-1? 0:i+1; };
long long GCD(long long a, long long b) {
  if (b == 0) return a;
  else return GCD(b, a % b);
}

using namespace std;
using namespace atcoder;
/* <-----------------------------------------------------------------------------------> */
/* <-----------------------------------------------------------------------------------> */
/* <-----------------------------------------------------------------------------------> */
/* <-----------------------------------------------------------------------------------> */
int main()
{
    int N, Q;
    cin >> N >> Q;
    fenwick_tree<int> fw(int N);
    rep(i, N) {
        int a;
        cin >> a;
        fw.add(i, a);
    rep(i, Q) {
        int a, b, c;
        cin >> a >> b >> c;
        //1点加算
        if (a == 0) { 
            fw.add(b, c);
            cout << fw.add(b, c) << "\n";
        }
        //区間和
        if (a == 1) {
            fw.sum(b, c);
            cout << fw.sum(b, c) << "\n";
        }
    }
    }
}


Compiler output:
a.cc:2:10: fatal error: atcoder/fenwicktree: No such file or directory
    2 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef unsigned long long LL;
typedef long double ld;
typedef vector<ll>VI;
typedef pair<int,int>P;
#define VV(T) vector<vector<T>>
#define sz(x) int(x.size())
#define PI 3.1415926535897932384626433832795
#define rep(i, n) for (ll i = 0; i < (ll)n; i++)
#define reprev(i,n) for (ll i=(ll)n-1;i>=0;i--)
#define ALL(a)  (a).begin(),(a).end()
#define rALL(a) (a).rbegin(),(a).rend()
#define c_max(a, b) (((ll)a)>((ll)b)?(a):(b))
#define c_min(a,b) (((ll)a)<((ll)b)?(a):(b))
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0; }
#define vmax(v) *max_element(ALL(v))
#define vmin(v) *min_element(ALL(v))
#define $(x) {cout<<#x<<" = " <<(x)<<endl;}
#define fi first
#define se second
#define MAX 100100//5
#define MAX2 200100
#define MAX6 1001001//6
#define MAX7 10010010//7
#define SENTINEL 2000000000//9
#define INF 1<<30
#define INFTY 1LL<<60
#define MAX_INT INT_MAX
#define Endl '\n'
#define CLR(mat) memset(mat, 0, sizeof(mat))
inline ll GCD(ll a,ll b){return b?GCD(b,a%b):a;}//最大公約数
inline ll lcm(ll a,ll b){return a*b/GCD(a,b);}//最小公倍数
template<class T> bool contain(const std::string& s, const T& v) {
   return s.find(v) != std::string::npos;
}
const int MOD = 1000000007;

inline ll mod_add(ll a,ll b){return (a+b)%MOD;}
inline ll mod_sub(ll a,ll b){return (a+MOD-b)%MOD;}
inline ll mod_mul(ll a,ll b){return ((a%MOD)*(b%MOD))%MOD;}
inline ll mod_pow(ll x,ll n,ll mod=(ll)MOD){ll res=1;while(n>0){
if(n&1)res=res*x%mod;
x=x*x%mod;n>>=1;}return res;}
inline ll mod_inv(ll x){return mod_pow(x,MOD-2);}
inline ll mod_div(ll a, ll b){return mod_mul(a,mod_inv(b));}
//const int dx[4]={1,0,-1,0},dy[4]={0,1,0,-1};
// vector型から重複を削除 list.erase(unique(ALL(list)),list.end());
// g++ -o a a.cpp -Wall -lm -std=c++17
//push_back -> emplace_back

#include <atcoder/fenwicktree>
using namespace atcoder;


int main(){
  int n, q;
  scanf("%d %d", &n, &q);
  
  fenwick_tree<long long> fw(n);
  for (int i = 0; i < n; i ++) {
    int a;
    scanf("%d", &a);
    fw.add(i, a);
  }
  
  for (int i = 0; i < q; i ++) {      
    int t, u, v;
    scanf("%d %d %d", &t, &u, & v);
    if (t == 0){
      fw.add(u, v);
    }
    else{
      printf("%lld\n", fw.sum(u, v));
    }
    
  }
    
  return 0;
  
}  


Compiler output:
a.cc:54:10: fatal error: atcoder/fenwicktree: No such file or directory
   54 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/all>
using namespace std;
using namespace atcoder;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define ALL(v) (v).begin(), (v).end()
using ll = long long;
constexpr int INF = 1e9;
constexpr long long LINF = 1e18;
constexpr long long MOD = 1e9 + 7;

template <typename T>
struct BIT {
    int n;
    vector<T> dat;

    BIT(int n) : n(n), dat(n + 1, 0) {}

    T sum(int idx) {
        T res(0);
        for (int i = idx; i > 0; i -= i & -i) res += dat[i];
        return res;
    }

    T sum(int l, int r) {
        return sum(r - 1) - sum(l - 1);
    }

    void add(int idx, T x) {
        if (idx == 0) return;
        for (int i = idx; i <= n; i += i & -i) dat[i] += x;
    }

    int lower_bound(T x) {
        if (x <= 0) return T(0);
        int res = 0, r = 1;
        while (r < n) r <<= 1;
        for (; r > 0; r >>= 1) {
            if (res + r <= n && dat[res + r] < x) {
                x -= dat[res + r];
                res += r;
            }
        }
        return res + 1;
    }

    T sum0(int idx) {
        return sum(idx + 1);
    }

    T sum0(int l, int r) {
        return sum(r) - sum(l);
    }

    void add0(int idx, T x) {
        add(idx + 1, x);
    }
};

signed main() {
    cin.tie(0);
    ios::sync_with_stdio(0);
    int n, q;
    cin >> n >> q;
    fenwick_tree<ll> bit(n);
    int a;
    rep(i, n) {
        cin >> a;
        bit.add(i, a);
    }
    int Q, p, x, l, r;
    rep(i, q) {
        cin >> Q;
        if (Q) {
            cin >> l >> r;
            cout << bit.sum(l, r) << endl;
        } else {
            cin >> p >> x;
            bit.add(p, x);
        }
    }
    return 0;
}

Compiler output:
a.cc:2:10: fatal error: atcoder/all: No such file or directory
    2 | #include <atcoder/all>
      |          ^~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <exception>
#include <fstream>
#include <functional>
#include <iomanip>
#include <ios>
#include <iosfwd>
#include <iostream>
#include <istream>
#include <iterator>
#include <limits>
#include <list>
#include <locale>
#include <map>
#include <memory>
#include <new>
#include <numeric>
#include <ostream>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <stdexcept>
#include <streambuf>
#include <string>
#include <typeinfo>
#include <utility>
#include <valarray>
#include <vector>
#include <climits>
#include <cstring>
#include <cassert>


using namespace std;
#define SZ(x) (int)(x.size())
#define REP(i, n) for(int i=0;i<n;++i)
#define FOR(i, a, b) for(int i=a;i<b;++i)
#define RREP(i, n) for(int i=n-1;i>=0;--i)
#define RFOR(i, a, b) for(int i=b-1;i>=a;--i)

#define all(x) begin(x),end(x)
#define dump(x) cerr<<#x<<" = "<<(x)<<endl
#define debug(x) cerr<<#x<<" = "<<(x)<<" (L"<<__LINE__<<")"<< endl;

using ll = long long;
using vi = vector<int>;
using vvi = vector<vi>;
using vll = vector<ll>;
using vvll = vector<vll>;
using P = pair<int, int>;
const double eps = 1e-8;
const ll MOD = 1000000007;
const int INF = INT_MAX / 2;
const ll LINF = LLONG_MAX / 2;

template<class T>
bool chmax(T &a, const T &b) {
    if (a < b) {
        a = b;
        return true;
    }
    return false;
}

template<class T>
bool chmin(T &a, const T &b) {
    if (b < a) {
        a = b;
        return true;
    }
    return false;
}


template<typename T1, typename T2>
ostream &operator<<(ostream &os, const pair<T1, T2> p) {
    os << p.first << ":" << p.second;
    return os;
}

template<class T>
ostream &operator<<(ostream &os, const vector<T> &v) {
    os << "[";
    REP(i, SZ(v)) {
        if (i) os << ", ";
        os << v[i];
    }
    return os << "]";
}

template<class T1, class T2>
ostream &operator<<(ostream &os, const map<T1, T2> &mp) {
    os << "[";
    for (auto it = mp.begin(); it != mp.end(); ++it) {
        if (it != mp.begin()) {
            os << ", ";
        }
        os << *it;
    }
    return os << "]";
}

// edit
#include <atcoder/all>

using namespace atcoder;

void solve() {
    int N, Q;
    cin >> N >> Q;
    fenwick_tree<ll> ft(N);
    REP(i, N) {
        ll a;
        cin >> a;
        ft.add(i, a);
    }
    while (Q--) {
        ll t, x, y;
        cin >> t >> x >> y;
        if (t == 0) {
            ft.add(x, y);
        } else {
            cout << ft.sum(x, y) << endl;
        }
    }

}


int main() {
    cin.tie(0);
    ios::sync_with_stdio(false);
    cout << fixed << setprecision(10);
//    std::ifstream in("input.txt");
//    std::cin.rdbuf(in.rdbuf());

    solve();


    return 0;
}


Compiler output:
a.cc:108:10: fatal error: atcoder/all: No such file or directory
  108 | #include <atcoder/all>
      |          ^~~~~~~~~~~~~
compilation terminated.
Language: C++

#pragma region
#define _USE_MATH_DEFINES
#include <iostream>
#include <string>
#include <algorithm>
#include <cmath>
#include <cstdlib>
#include <vector>
#include <map>
#include <queue>
#include <stack>
#include <set>
#include <list>
#include <iomanip>
#include <cstdint>
#include <bitset>
#include <sstream>
#include <regex>
#include <atcoder/fenwicktree>

using namespace std;
using namespace atcoder;
typedef long long ll;
//#define rep(i, s, e) for (int(i) = (s); (i) < (e); ++(i))
#define rep(i, e) for (int(i) = 0; (i) < (e); ++(i))
#define rrep(i, s) for (int(i) = (s) - 1; (i) >= 0; --(i))
#define all(x) x.begin(),x.end()

#pragma region UnionFind
struct UnionFind
{
	vector<int> par;

	UnionFind(int n) : par(n, -1) {}
	void init(int n) { par.assign(n, -1); }

	int root(int x)
	{
		if (par[x] < 0) return x;
		else return par[x] = root(par[x]);
	}

	bool issame(int x, int y)
	{
		return root(x) == root(y);
	}

	bool merge(int x, int y)
	{
		x = root(x); y = root(y);
		if (x == y) return false;
		if (par[x] > par[y]) swap(x, y);
		par[x] += par[y];
		par[y] = x;
		return true;
	}

	int size(int x)
	{
		return -par[root(x)];
	}
};
#pragma endregion
#pragma region GCD
ll gcd(ll a, ll b)
{
	if (b == 0)return a;
	return gcd(b, a%b);
}
#pragma endregion
#pragma region LCM
ll lcm(ll a, ll b)
{
	return a / gcd(a, b) * b;
}
#pragma endregion
#pragma region chmin
template<class T> inline bool chmin(T& a, T b)
{
	if (a > b)
	{
		a = b;
		return true;
	}
	return false;
}
#pragma endregion
#pragma region chmax
template<class T> inline bool chmax(T& a, T b)
{
	if (a < b)
	{
		a = b;
		return true;
	}
	return false;
}
#pragma endregion
#pragma endregion


int main()
{
	int n, q; cin >> n >> q;
	fenwick_tree<ll> fw(n);
	rep(i, n)
	{
		int a; cin >> a;
		fw.add(i, a);
	}
	while (q--)
	{
		int query; cin >> query;
		if (query == 0)
		{
			int p, x; cin >> p >> x;
			fw.add(p, x);
		}
		else
		{
			int l, r; cin >> l >> r;
			cout << fw.sum(l, r) << endl;
		}
	}
}

Compiler output:
a.cc:19:10: fatal error: atcoder/fenwicktree: No such file or directory
   19 | #include <atcoder/fenwicktree>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#include <atcoder/all>

using namespace std;
using namespace atcoder;

typedef long long ll;
#define REP(i,n) for(int i=0,_n=(int)(n);i<_n;++i)
#define ALL(v) (v).begin(),(v).end()
#define CLR(t,v) memset(t,(v),sizeof(t))
template<class T1,class T2>ostream& operator<<(ostream& os,const pair<T1,T2>&a){return os<<"("<<a.first<<","<<a.second<< ")";}
template<class T>void pv(T a,T b){for(T i=a;i!=b;++i)cout<<(*i)<<" ";cout<<endl;}
template<class T>void chmin(T&a,const T&b){if(a>b)a=b;}
template<class T>void chmax(T&a,const T&b){if(a<b)a=b;}

ll nextLong() { ll x; scanf("%lld", &x); return x;}


int main2() {
  int N = nextLong();
  int Q = nextLong();
  fenwick_tree<ll> fw(N+10);
  REP(i, N) {
    int x = nextLong();
    fw.add(i, x);
  }
  REP(qqq, Q) {
    int t = nextLong();
    if (t == 0) {
      int p = nextLong();
      int x = nextLong();
      fw.add(p, x);
    }
    else
    {
      int l = nextLong();
      int r = nextLong();
      ll ans = fw.sum(l, r);
      cout << ans << '\n';
    }
  }

  
  return 0;
}

int main() {

#ifdef LOCAL
  for (;!cin.eof();cin>>ws)
#endif
    main2();
  return 0;
}

Compiler output:
a.cc:2:10: fatal error: atcoder/all: No such file or directory
    2 | #include <atcoder/all>
      |          ^~~~~~~~~~~~~
compilation terminated.
Language: C++

#include<bits/stdc++.h>
#include<atcoder/fenwicktree>
using namespace std;
using namespace atcoder;
int main(){
    int n, q;
    cin >> n >> q;
    fenwick_tree<long long> a(n);
    for(int i = 0; i < n; i++){
        int p;
        cin >> p;
        a.add(i,p);
    }
    for(int i = 0; i < q; i++){
        int t;
        cin >> t;
        if(t == 0){
            int p, x;
            cin >> p >> x;
            a.add(p, x);
        }
        else{
            int l, r;
            cin >> l >> r;
            cout << (long long) a.sum(l. r) << endl;
        }
    }
    return 0;
}

Compiler output:
a.cc:2:9: fatal error: atcoder/fenwicktree: No such file or directory
    2 | #include<atcoder/fenwicktree>
      |         ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.