Flatten a list without type coercion

Description

Flatten a list without type coercion

Usage

1
flatten2(x, len = 1024)

Arguments

x

a nested list

len

guess of output length

Changed Feb 19, 2015 by njf

Rather than calculating length, preallocate more than needed.

Author(s)

Tommy, Joshua Ulrich, Josh O'Brien, Neal Fultz

References

http://stackoverflow.com/questions/8139677/how-to-flatten-a-list-to-a-list-without-coercion