You must be logged in to add problems to this category

Segment Tree problems
Problem Name Online Judge Year Contest Difficulty Level
1 K-th Number Categories SPOJ 1
2 Flipping Coins Categories CodeChef 1
3 Largest Rectangle in a Histogram Categories SPOJ 1
4 Multiples of 3 Categories SPOJ 1
5 Query on a tree again! Categories SPOJ 1
6 Horrible Queries Categories SPOJ 1
7 Brackets Categories SPOJ 1
8 Find String Roots Categories SPOJ 1
9 Ordering the Soldiers Categories SPOJ 1
10 The day of the competitors Categories SPOJ 1
11 Frequent values Categories SPOJ 1
12 Order statistic set Categories SPOJ 1
13 Can you answer these queries V Categories SPOJ 1
14 Sum of Squares with Segment Tree Categories SPOJ 1
15 Xenia and Bit Operations Categories Codeforces Codeforces Round #197 (Div. 2) 1
16 Can you answer these queries IV Categories SPOJ 1
17 D-query Categories SPOJ 1
18 Interval Product Categories Live Archive 2012 Latin America 1
19 Can you answer these queries III Categories SPOJ 1
20 AND Rounds Categories SPOJ 1
21 Roti Prata Categories SPOJ 1
22 K-query Categories SPOJ 1
23 Can you answer these queries II Categories SPOJ 1
24 Election Posters Categories SPOJ 1
25 Count on a tree Categories SPOJ 1
26 Negative Score Categories SPOJ 1
27 Coin Flip Categories CodeChef 1
28 Can you answer these queries I Categories SPOJ 1
29 Yodaness Level Categories SPOJ 1
30 Inversion Count Categories SPOJ 1
31 Potentiometers Categories UVA 1
32 Interval Product Categories UVA 1
33 Frequent values Categories UVA 1
34 Maximum Sum Categories SPOJ 1
35 Light Switching Categories SPOJ 1
36 The Great Ball Categories SPOJ 1
37 Light Switching Categories TJU 2
38 Counting Primes Categories SPOJ 2
39 Chef and medium problem 2 Categories CodeChef 2
40 Help R2-D2! Categories SPOJ 2
41 Frequent values Categories TJU 2
42 WIND VANE Categories SPOJ 2
43 Greg and Array Categories Codeforces Codeforces Round #179 (Div. 1) & Codeforces Round #179 (Div. 2) 2
44 Stern-Brocot Tree Categories UVA 2
45 Handball Categories UVA 2
46 Race Against Time Categories SPOJ 2
47 Mummy Madness Categories Live Archive 2011 World Finals - Orlando 2
48 Can you answer these queries VII Categories SPOJ 2
49 Query on a tree V Categories SPOJ 2
50 Living with Courage Categories SPOJ 2
51 Snow White and the N dwarfs Categories SPOJ 2
52 Can you answer these queries VI Categories SPOJ 2
53 Brackets II Categories SPOJ 2
54 Query on a tree IV Categories SPOJ 2
55 Ahoy, Pirates! Categories UVA 2
56 Binary Search Heap Construction Categories SPOJ 3
57 Interval Product Categories URI 3
58 Sereja and Brackets Categories Codeforces Codeforces Round #223 (Div. 1) & Codeforces Round #223 (Div. 2) 3
59 Congruence Equation Categories SPOJ 3
60 Blue Mary Needs Help Again Categories SPOJ 3
61 Dima and Staircase Categories Codeforces Codeforces Round #167 (Div. 2) & Codeforces Round #167 (Div. 1) 3
62 Maximum number, GCD condition Categories CodeChef 3
63 Temple Queues Categories SPOJ 3
64 Modular Equations Categories Codeforces Codeforces Round #282 (Div. 2) 3
65 K-query II Categories SPOJ 3
66 GM plants Categories SPOJ 3
67 Query on a tree VI Categories SPOJ 3
68 Sum of Distinct Numbers Categories SPOJ 3
69 Salary Management Categories SPOJ 3
70 Pashmak and Parmida's problem Categories Codeforces Codeforces Round #261 (Div. 2) 3
71 SKYLINE Categories UVA 3
72 Multiply Game Categories TJU 3
73 Interesting Array Categories Codeforces Codeforces Round #275 (Div. 1) & Codeforces Round #275 (Div. 2) 3
74 Lucky Number Categories UVA 3
75 Xor Queries Categories CodeChef 3
76 Squares Categories Live Archive 2004 North America - Rocky Mountain 3
77 Little Elephant and Array Categories Codeforces Codeforces Round #136 (Div. 1) & Codeforces Round #136 (Div. 2) 3
78 Destroying Array Categories Codeforces Intel Code Challenge Elimination Round (Div. 1 + Div. 2, combined) 3
79 GCD 2010 Categories Timus 3
80 ForbiddenSum Categories CodeChef 3
81 ``Dynamic'' Inversion Categories UVA 4
82 Babaei and Birthday Cake Categories Codeforces Codeforces Round #343 (Div. 2) 4
83 Brute-force Algorithm Categories Live Archive 2009 Asia - Shanghai 4
84 Ant colony Categories Codeforces Codeforces Round #271 (Div. 2) 4
85 Query on a tree VII Categories SPOJ 4
86 Nested Segments Categories Timus 4
87 Preparing for Merge Sort Categories Codeforces 2017-2018 ACM-ICPC, NEERC, Southern Subregional Contest, qualification stage (Online Mirror, ACM-ICPC Rules, Teams Preferred) 4
88 Impossible Boss Categories SPOJ 4
89 LCM GCD Love Categories SPOJ 4
90 Propagating tree Categories Codeforces Codeforces Round #225 (Div. 1) & Codeforces Round #225 (Div. 2) 4
91 Enemy is weak Categories Codeforces Codeforces Beta Round #57 (Div. 2) 4
92 Bash and a Tough Math Puzzle Categories Codeforces Codecraft-18 and Codeforces Round #458 (Div. 1 + Div. 2, combined) 4
93 Roots of a Tree Categories CodeChef 4
94 Circular RMQ Categories Codeforces Codeforces Testing Round #1 4
95 Enjoy Sum with Operations Categories SPOJ 4
96 The Closest Pair Categories Codeforces Codeforces Round #185 (Div. 1) & Codeforces Round #185 (Div. 2) 4
97 01 Sequence Categories SPOJ 4
98 Who is The Boss Categories SPOJ 4
99 XOR Minimization Categories CodeChef 4
100 XOR on Segment Categories Codeforces Codeforces Round #149 (Div. 2) 4
101 Misha and Permutations Summation Categories Codeforces Codeforces Round #285 (Div. 2) & Codeforces Round #285 (Div. 1) 5
102 A Simple Task Categories Codeforces Codeforces Round #312 (Div. 2) 5
103 Fun with AGp Categories CodeChef 5
104 Pillars Categories Codeforces Codeforces Round #271 (Div. 2) 5
105 R2D2 and Droid Army Categories Codeforces Codeforces Round #291 (Div. 2) 5
106 PolandBall and Polygon Categories Codeforces 8VC Venture Cup 2017 - Elimination Round 5
107 Cards Sorting Categories Codeforces Codeforces Round #424 (Div. 1, rated, based on VK Cup Finals) & Codeforces Round #424 (Div. 2, rated, based on VK Cup Finals) 5
108 Factory Repairs Categories Codeforces 8VC Venture Cup 2016 - Final Round 5
109 SUM and REPLACE Categories Codeforces Educational Codeforces Round 37 (Rated for Div. 2) 5
110 The Child and Sequence Categories Codeforces Codeforces Round #250 (Div. 1) 5
111 Rectangle Query Categories CodeChef 5
112 Copying Data Categories Codeforces Croc Champ 2013 - Round 1 5
113 Water Tree Categories Codeforces Codeforces Round #200 (Div. 1) 5
114 Rip Van Winkle's Code Categories UVA 5
115 Mishka and Interesting sum Categories Codeforces Codeforces Round #365 (Div. 2) 5
116 Tree and Queries Categories Codeforces Codeforces Round #221 (Div. 1) 5
117 Danil and a Part-time Job Categories Codeforces Codeforces Round #442 (Div. 2) 5
118 Valera and Queries Categories Codeforces Codeforces Round #216 (Div. 2) 6
119 Lucky Queries Categories Codeforces Codeforces Round #104 (Div. 1) 6
120 DZY Loves Fibonacci Numbers Categories Codeforces Codeforces Round #255 (Div. 1) & Codeforces Round #255 (Div. 2) 6
121 Turn Off The TV Categories Codeforces Educational Codeforces Round 29 6
122 Drazil and Park Categories Codeforces Codeforces Round #292 (Div. 2) & Codeforces Round #292 (Div. 1) 6
123 Segment Tree Categories SPOJ 6
124 DZY Loves Colors Categories Codeforces Codeforces Round #254 (Div. 1) & Codeforces Round #254 (Div. 2) 6
125 Kefa and Watch Categories Codeforces Codeforces Round #321 (Div. 2) 6
126 Save the Python Programmers! Categories Live Archive 2010 North America - Pacific Northwest 6
127 On Changing Tree Categories Codeforces Codeforces Round #232 (Div. 1) & Codeforces Round #232 (Div. 2) 6
128 New Year Domino Categories Codeforces Good Bye 2014 6
129 Yaroslav and Divisors Categories Codeforces Codeforces Round #182 (Div. 1) 6
130 High and Low Categories SPOJ 6
131 Infinite Inversions Categories Codeforces Codeforces Round #301 (Div. 2) 6
132 Subsequences Categories Codeforces Testing Round #12 6
133 Blogger language Categories UVA 7
134 Kool Konstructions Categories UVA 7
135 Union on Tree Categories CodeChef 7
136 Little Girl and Problem on Trees Categories Codeforces Codeforces Round #169 (Div. 2) 7
137 Domino Principle Categories Codeforces Codeforces Beta Round #52 (Div. 2) 7
138 Lucky Array Categories Codeforces Codeforces Beta Round #91 (Div. 1 Only) 7
139 Count The Indexes 2 Categories SPOJ 7
140 Points Categories Codeforces Codeforces Beta Round #19 7
141 Segments Categories A2 Online Judge 7
142 Little Elephant and Inversions Categories Codeforces Codeforces Round #136 (Div. 1) 7
143 Vika and Segments Categories Codeforces Codeforces Round #337 (Div. 2) 7
144 Sign on Fence Categories Codeforces Codeforces Round #276 (Div. 1) 7
145 Allowance Categories URI 7
146 Army Creation Categories Codeforces Educational Codeforces Round 22 7
147 Drazil and Morning Exercise Categories Codeforces Codeforces Round #292 (Div. 1) 8
148 Alphabet Permutations Categories Codeforces Codeforces Round #337 (Div. 2) 8
149 Jeff and Removing Periods Categories Codeforces Codeforces Round #204 (Div. 1) 8
150 Eyes Closed Categories Codeforces Codeforces Round #448 (Div. 2) 8
151 Optimize! Categories Codeforces Codeforces Round #196 (Div. 1) 8
152 Linear Kingdom Races Categories Codeforces Codeforces Beta Round #87 (Div. 1 Only) 8
153 Misha and Palindrome Degree Categories Codeforces Codeforces Round #285 (Div. 2) & Codeforces Round #285 (Div. 1) 8
154 REQ Categories Codeforces Codeforces Round #330 (Div. 1) 8
155 Ada and Species Categories SPOJ 8
156 TorCoder Categories Codeforces Codeforces Round #145 (Div. 1, ACM-ICPC Rules) 8
157 Function Categories Codeforces Codeforces Round #260 (Div. 1) 9
158 Camping Groups Categories Codeforces Croc Champ 2012 - Round 1 9
159 To the moon Categories TJU 10
160 Nikita Categories Timus 10
161 #dynamic-programming&nbsp;(168)</span> Categories SPOJ 10
162 Tree or not Tree Categories Codeforces Codeforces Beta Round #88 10