[ < ] | [ > ] |  | [ << ] | [ Up ] | [ >> ] |  |  |  |  | [Top] | [Contents] | [Index] | [ ? ]

#### 2.7.14.3 Distribute

The function with the following virtual code representation is frequently useful for manipulating lists.

T30

  `distribute` = `(((nil,nil),nil),nil)`

This function takes a pair whose right side represents a list, and returns a list of pairs, with one pair for each item in the list. The left side of each pair is the left side of the original argument, and the right side is the corresponding item of the list. A semantics for this operation is specified by the following properties.

P39

  [[`distribute`]] `(x,nil)` = `nil`

P40

  [[`distribute`]] `(x,(y,z))` = `((x,y),`[[`distribute`]] `(x,z))`

This document was generated on November 8, 2012 using texi2html 1.82.