Implemented array storage
This commit is contained in:
parent
d35c07ed1c
commit
155df7c44c
17 changed files with 150 additions and 45 deletions
13
examples/array/array.q
Normal file
13
examples/array/array.q
Normal file
|
@ -0,0 +1,13 @@
|
|||
import mem
|
||||
import sys
|
||||
|
||||
main() {
|
||||
length := 4
|
||||
address := mem.alloc(length)
|
||||
address[0] = 65
|
||||
address[1] = 66
|
||||
address[2] = 67
|
||||
address[3] = 68
|
||||
sys.write(1, address, length)
|
||||
mem.free(address, length)
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue