Skip to content

Commit 5c24f28

Browse files
committed
Update
1 parent c023f14 commit 5c24f28

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

cp-algo/graph/cycle.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ namespace cp_algo::graph {
88
struct cycle_context: dfs_context<graph> {
99
using base = dfs_context<graph>;
1010
using base::base;
11-
std::deque<edge_index> cycle;
11+
big_deque<edge_index> cycle;
1212
bool closed = false;
1313
int v0;
1414

@@ -30,7 +30,7 @@ namespace cp_algo::graph {
3030
};
3131

3232
template<graph_type graph>
33-
std::pair<node_index, std::deque<edge_index>> find_cycle(graph const& g) {
33+
std::pair<node_index, big_deque<edge_index>> find_cycle(graph const& g) {
3434
auto context = dfs<cycle_context>(g);
3535
return {context.v0, context.cycle};
3636
}

cp-algo/graph/euler.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ namespace cp_algo::graph {
4545
// Try finding a trail starting from v0
4646
// may be partial if graph is not Eulerian or disconnected
4747
template<graph_type graph>
48-
std::deque<edge_index> try_euler_trail(graph const& g, node_index v0) {
49-
std::deque<edge_index> trail;
48+
big_deque<edge_index> try_euler_trail(graph const& g, node_index v0) {
49+
big_deque<edge_index> trail;
5050
enum state { unvisited, visited };
5151
big_vector<state> state(g.m());
5252
auto const& adj = g.incidence_lists();
@@ -83,7 +83,7 @@ namespace cp_algo::graph {
8383
return trail;
8484
}
8585
template<graph_type graph>
86-
std::optional<std::pair<node_index, std::deque<edge_index>>> euler_trail(graph const& g) {
86+
std::optional<std::pair<node_index, big_deque<edge_index>>> euler_trail(graph const& g) {
8787
auto v0 = euler_start(g);
8888
if (!v0) {
8989
return std::nullopt;

cp-algo/structures/eertree.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ namespace cp_algo::structures {
1111
struct eertree {
1212
eertree(size_t q) {
1313
q += 2;
14-
s = std::string(q, -1);
14+
s = big_string(q, -1);
1515
len = par = link = big_vector(q, 0);
1616
to.resize(q);
1717
link[0] = 1;
@@ -65,7 +65,7 @@ namespace cp_algo::structures {
6565
private:
6666
big_vector<std::forward_list<int>> to;
6767
big_vector<int> len, link, par;
68-
std::string s;
68+
big_string s;
6969
int n = 1, sz = 2, last = 0;
7070
};
7171
}

0 commit comments

Comments
 (0)