From 8723fe078180916a6b2f736232e7f5bec2b9674e Mon Sep 17 00:00:00 2001 From: Benji Dial Date: Sun, 26 Nov 2023 20:28:29 -0500 Subject: add function to lib94 to remove all warriors; fix crash on removing last warrior in bench --- include/lib94/lib94.hpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include') diff --git a/include/lib94/lib94.hpp b/include/lib94/lib94.hpp index 40c9631..63f862e 100644 --- a/include/lib94/lib94.hpp +++ b/include/lib94/lib94.hpp @@ -108,6 +108,8 @@ namespace lib94 { //with the current time, before the first time you call this. bool init_round(const warrior *const *warriors, size_t count, const number_t *offsets, bool shuffle); + void remove_all_warriors(); + //returns the number of warriors who have at least one process size_t alive_warrior_count(); -- cgit v1.2.3