A pair of lists

Discussion of Scheme and Racket
Post Reply
Posts: 45
Joined: Tue Dec 14, 2010 1:39 am

A pair of lists

Post by saulgoode » Sat Apr 20, 2013 4:30 am

I am writing a tutorial on developing a Scheme compiler and one of the data structures I am using is a pair of lists, where the car of the pair is a list of the symbols and the cdr of the pair is a list of their values.

For example, an a-list of the data might be '((a . 10) (b . 20) (c . 30))
And the p-list version would be '((a 10) (b 20) (c 30))
My data structure would be '((a b c) 10 20 30)

I am wondering if there is a common name for such a data structure (along the lines of a-list and p-list).

Post Reply