aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorThomas Schmucker <ts@its1.de>2024-01-02 19:09:19 +0100
committerThomas Schmucker <ts@its1.de>2024-01-02 19:09:19 +0100
commite95d22d3927549caa5c259a59aedaa67d3b636ca (patch)
tree328693ef3c659d6cd91775ed21078ef43c41d622 /src
parent65b5b7cdfc1bc4aa9e358fdeddfecdd9951a0302 (diff)
downloadadvent-of-code-e95d22d3927549caa5c259a59aedaa67d3b636ca.tar.gz
advent-of-code-e95d22d3927549caa5c259a59aedaa67d3b636ca.tar.bz2
advent-of-code-e95d22d3927549caa5c259a59aedaa67d3b636ca.zip
fix bug
Diffstat (limited to 'src')
-rw-r--r--src/day25.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/day25.cpp b/src/day25.cpp
index aaad9e9..1d5e19e 100644
--- a/src/day25.cpp
+++ b/src/day25.cpp
@@ -79,7 +79,7 @@ random_node(const graph_type& graph)
79 static random_device dev; 79 static random_device dev;
80 static mt19937 generator(dev()); 80 static mt19937 generator(dev());
81 81
82 uniform_int_distribution<graph_type::size_type> distribute(0, graph.size()); 82 uniform_int_distribution<graph_type::size_type> distribute(0, graph.size()-1);
83 83
84 auto iter = graph.begin(); 84 auto iter = graph.begin();
85 advance(iter, distribute(generator)); 85 advance(iter, distribute(generator));