File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
library/data_structures_[l,r] Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 4444"tests/library_checker_aizu_tests/data_structures/rmq_sparse_table.test.cpp" : " 2026-01-18 11:15:41 +0000" ,
4545"tests/library_checker_aizu_tests/data_structures/rmq_sparse_table_inc.test.cpp" : " 2026-01-18 11:15:41 +0000" ,
4646"tests/library_checker_aizu_tests/data_structures/simple_tree.test.cpp" : " 2026-01-18 11:15:41 +0000" ,
47- "tests/library_checker_aizu_tests/data_structures/simple_tree_inc.test.cpp" : " 2026-01-22 19:22:57 -0700" ,
48- "tests/library_checker_aizu_tests/data_structures/simple_tree_inc_line.test.cpp" : " 2026-01-22 19:22:57 -0700" ,
47+ "tests/library_checker_aizu_tests/data_structures/simple_tree_inc.test.cpp" : " 2026-01-22 19:46:25 -0700" ,
48+ "tests/library_checker_aizu_tests/data_structures/simple_tree_inc_line.test.cpp" : " 2026-01-22 19:46:25 -0700" ,
4949"tests/library_checker_aizu_tests/data_structures/simple_tree_line.test.cpp" : " 2026-01-18 11:15:41 +0000" ,
5050"tests/library_checker_aizu_tests/flow/dinic_aizu.test.cpp" : " 2024-11-17 14:04:03 -0600" ,
5151"tests/library_checker_aizu_tests/flow/hungarian.test.cpp" : " 2024-11-17 14:04:03 -0600" ,
Original file line number Diff line number Diff line change 1111// ! @time O(n + q log n)
1212// ! @space O(n)
1313int nxt (int & l, int r) {
14- int x = __lg (min (l & -l, r - l + 1 ));
15- return exchange (l, l + ( 1 << x)) >> x ;
14+ int x = l, y = __lg (min (l & -l, r - l + 1 ));
15+ return l += 1 << y, x >> y ;
1616}
1717template <class T , class F > struct tree {
1818 int n;
You can’t perform that action at this time.
0 commit comments