wiki:DataStructures

Version 2 (modified by schiptsov, 9 years ago) ( diff )

--

use annotations for the compiler to choice appropriate built-in primitives.

cons:

(a . b)

list (could be annotated as a set, one-dimension array, etc)

(1 "two" 3 (4 5))

(1 . ("two" . (3 . (4 . ((5 . nil) nil))))

vecror:

((1)
 (2)
 (3))

matrix:

((1 2 3)
 (3 4 5)
 (6 7 8))

associative array:

(("a" . 1)
 ("b" . 2)
 ("c" . '(1 2 3)))

hash table:

table could be "called" by sending a message (t "orange") => 2

(("apple" . 1)
 ("orange" . 2)
 ("grapes" . 3))
Note: See TracWiki for help on using the wiki.