Added the following attributes:

* table.length
* table.insert(key,value)
* table.hasKey(key)
* table.remove(key)

There's basically only iteration and sorting left.
This commit is contained in:
2026-04-24 23:01:57 +10:00
parent 88e9794952
commit 0c24a7609e
3 changed files with 104 additions and 24 deletions
+15 -3
View File
@@ -1,6 +1,18 @@
var array = [1,2,3];
array.pushBack(4);
var table: Table = ["answer":42];
print table.hasKey("answer");
print table.hasKey("question");
table.insert("question", "roads");
print table.hasKey("answer");
print table.hasKey("question");
table.remove("answer");
print table.hasKey("answer");
print table.hasKey("question");
print array.popBack();