summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/sequence.h')
-rw-r--r--src/core/sequence.h23
1 files changed, 21 insertions, 2 deletions
diff --git a/src/core/sequence.h b/src/core/sequence.h
index fb4b628..e609b4d 100644
--- a/src/core/sequence.h
+++ b/src/core/sequence.h
@@ -2,7 +2,7 @@
#define _ZoO_CORE_SEQUENCE_H_
#include "../core/index_types.h"
-#include "../core/knownledge_types.h"
+#include "../core/knowledge_types.h"
#include "sequence_types.h"
@@ -27,7 +27,7 @@
* (knows {k} {initial_word})
* (initialized {k})
*/
-int ZoO_create_sequence_from
+int ZoO_sequence_create_from
(
const ZoO_index initial_word,
ZoO_index credits [const restrict],
@@ -37,4 +37,23 @@ int ZoO_create_sequence_from
size_t sequence_size [const restrict static 1]
);
+/*
+ * Compares two sequences.
+ * ZoO_END_OF_SEQUENCE marks the ending of a sequence, regardless of indicated
+ * sequence length, meaning that [10][ZoO_END_OF_SEQUENCE][9] and
+ * [10][ZoO_END_OF_SEQUENCE][8] are considered equal. Sequences do not have to
+ * contain ZoO_END_OF_SEQUENCE.
+ * Return:
+ * 1 iff {sequence_a} should be considered being more than {sequence_b}
+ * 0 iff {sequence_a} should be considered being equal to {sequence_b}
+ * -1 iff {sequence_a} should be considered being less than {sequence_b}
+ */
+int ZoO_sequence_cmp
+(
+ const ZoO_index sequence_a [const],
+ const ZoO_index sequence_a_length,
+ const ZoO_index sequence_b [const],
+ const ZoO_index sequence_b_length
+);
+
#endif