Skip to content

Commit 03f2e44

Browse files
authored
chore(formatting): apply code formatting for range query Fenwicj
1 parent 7022cfc commit 03f2e44

File tree

1 file changed

+7
-16
lines changed

1 file changed

+7
-16
lines changed
Lines changed: 7 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
1-
template <typename T>
2-
class Fenwick {
3-
public:
1+
template <typename T> class Fenwick {
2+
public:
43
vector<T> fenw;
54
int n;
65

7-
Fenwick(int _n) : n(_n) {
8-
fenw.resize(n);
9-
}
6+
Fenwick(int _n) : n(_n) { fenw.resize(n); }
107
void modify(int x, T v) {
118
while (x < n) {
129
fenw[x] += v;
@@ -29,17 +26,11 @@ class Fenwick {
2926
// }
3027
};
3128

32-
template<typename T>
33-
using fenwick = Fenwick<T>;
29+
template <typename T> using fenwick = Fenwick<T>;
3430

3531
struct node {
3632
// don't forget to set default value
3733
int a = ...;
38-
inline void operator+=(const node &other) {
39-
...
40-
}
41-
inline node operator-(const node &other) {
42-
...
43-
return *this;
44-
}
45-
};
34+
inline void operator+=(const node &other) { ... }
35+
inline node operator-(const node &other) { ... return *this; }
36+
};

0 commit comments

Comments
 (0)