Implementing Binary Search Trees in GP 2 (Extended Abstract)
Fuente:
arXiv
Saved in:
| Main Authors: | , |
|---|---|
| Format: | Preprint |
| Published: |
2026
|
| Subjects: | |
| Online Access: | |
| Tags: |
Add Tag
No Tags, Be the first to tag this record!
|
| _version_ | 1866908751678668800 |
|---|---|
| author | Alaoui, Ziad Ismaili Plump, Detlef |
| author_facet | Alaoui, Ziad Ismaili Plump, Detlef |
| contents | We present an approach to implement binary search trees in the rule-based graph programming language GP 2. Our implementation uses GP 2's rooted graph transformation rules to be fast and supports insertion, deletion and query operations. We argue that the worst-case runtime for each of the operations is O(n) for a tree with n nodes. In addition, we expect that, on average, the operations run in time O(log(n)). Hence the implementation would match the time complexity of binary search trees implementations in imperative languages. |
| format | Preprint |
| id |
arxiv_https___arxiv_org_abs_2601_03897 |
| institution | arXiv |
| publishDate | 2026 |
| record_format | arxiv |
| spellingShingle | Implementing Binary Search Trees in GP 2 (Extended Abstract) Alaoui, Ziad Ismaili Plump, Detlef Programming Languages Data Structures and Algorithms We present an approach to implement binary search trees in the rule-based graph programming language GP 2. Our implementation uses GP 2's rooted graph transformation rules to be fast and supports insertion, deletion and query operations. We argue that the worst-case runtime for each of the operations is O(n) for a tree with n nodes. In addition, we expect that, on average, the operations run in time O(log(n)). Hence the implementation would match the time complexity of binary search trees implementations in imperative languages. |
| title | Implementing Binary Search Trees in GP 2 (Extended Abstract) |
| topic | Programming Languages Data Structures and Algorithms |
| url | https://arxiv.org/abs/2601.03897 |