Recently, I've just encountered this problem: Given a tree with $$$n$$$ vertices and rooted at $$$1$$$. Each vertex has an initial value, and initially, all these values are $$$0$$$.
Constraints
# | User | Rating |
---|---|---|
1 | tourist | 3985 |
2 | jiangly | 3814 |
3 | jqdai0815 | 3682 |
4 | Benq | 3529 |
5 | orzdevinwang | 3526 |
6 | ksun48 | 3517 |
7 | Radewoosh | 3410 |
8 | hos.lyric | 3399 |
9 | ecnerwala | 3392 |
9 | Um_nik | 3392 |
# | User | Contrib. |
---|---|---|
1 | cry | 169 |
2 | maomao90 | 162 |
2 | Um_nik | 162 |
4 | atcoder_official | 160 |
5 | djm03178 | 158 |
5 | -is-this-fft- | 158 |
7 | adamant | 155 |
8 | Dominater069 | 154 |
9 | awoo | 152 |
10 | luogu_official | 150 |
How to update path with Euler Tour?
Recently, I've just encountered this problem: Given a tree with $$$n$$$ vertices and rooted at $$$1$$$. Each vertex has an initial value, and initially, all these values are $$$0$$$.
Constraints
Rev. | Lang. | By | When | Δ | Comment | |
---|---|---|---|---|---|---|
en24 | ak2k8 | 2024-11-19 18:19:28 | 84 | |||
en23 | ak2k8 | 2024-11-19 18:13:20 | 0 | (published) | ||
en22 | ak2k8 | 2024-11-19 18:12:16 | 78 | |||
en21 | ak2k8 | 2024-11-19 18:11:43 | 8 | Tiny change: 'problem:$\\$\nGiven a' -> 'problem:$\newline$\nGiven a' | ||
en20 | ak2k8 | 2024-11-19 18:11:30 | 7 | Tiny change: 's problem:\n$$ $$\nGiven a' -> 's problem:$\\$\nGiven a' | ||
en19 | ak2k8 | 2024-11-19 18:10:45 | 210 | |||
en18 | ak2k8 | 2024-11-19 18:06:33 | 43 | |||
en17 | ak2k8 | 2024-11-19 18:05:57 | 1 | Tiny change: 'oblem:\n$$ $$\nGiven ' -> 'oblem:\n$$$$\nGiven ' | ||
en16 | ak2k8 | 2024-11-19 18:05:40 | 3 | Tiny change: 'oblem:\n$$\\$$\nGiven ' -> 'oblem:\n$$ $$\nGiven ' | ||
en15 | ak2k8 | 2024-11-19 18:05:25 | 4 | Tiny change: 'problem:\n\\\nGiven a ' -> 'problem:\n$$\\$$\nGiven a ' | ||
en14 | ak2k8 | 2024-11-19 18:05:09 | 2 | Tiny change: 'problem:\n$\\$\nGiven a ' -> 'problem:\n\\\nGiven a ' | ||
en13 | ak2k8 | 2024-11-19 18:04:36 | 1 | Tiny change: 'blem:\n$\\\$\nGiven' -> 'blem:\n$\\$\nGiven' | ||
en12 | ak2k8 | 2024-11-19 18:04:21 | 2 | Tiny change: 'problem:\n\\\\nGiven a ' -> 'problem:\n$\\\$\nGiven a ' | ||
en11 | ak2k8 | 2024-11-19 18:04:08 | 3 | Tiny change: ' problem:\\\nGiven ' -> ' problem:\n\\\\nGiven ' | ||
en10 | ak2k8 | 2024-11-19 18:03:48 | 49 | |||
en9 | ak2k8 | 2024-11-19 18:01:45 | 4 | Tiny change: 's problem:\ncut\nGiven a ' -> 's problem:[cut]\nGiven a ' | ||
en8 | ak2k8 | 2024-11-19 18:01:30 | 2 | Tiny change: 'problem:\n[cut]\nGiven a ' -> 'problem:\ncut\nGiven a ' | ||
en7 | ak2k8 | 2024-11-19 18:01:15 | 49 | |||
en6 | ak2k8 | 2024-11-19 17:59:00 | 20 | |||
en5 | ak2k8 | 2024-11-19 17:58:18 | 26 | |||
en4 | ak2k8 | 2024-11-19 17:56:59 | 12 | |||
en3 | ak2k8 | 2024-11-19 17:56:26 | 2 | Tiny change: 'ree with $$n$$ vertices' -> 'ree with $n$ vertices' | ||
en2 | ak2k8 | 2024-11-19 17:56:03 | 30 | |||
en1 | ak2k8 | 2024-11-19 17:54:56 | 597 | Initial revision (saved to drafts) |
Name |
---|