Converting a list of digits to a number
问题 I was wondering if there was a way to take a list of numbers (digits), and truncate the numbers together to be one large number (not addition) in Scheme. For example, I would want (foo '(1 2 3 4)) ;=> 1234 Does Scheme have a built in function to do this? 回答1: There are a number of languages that are in the Scheme family, and there are a few versions of Scheme, too. If you're using one, e.g., Racket, that includes a left associative fold (often called foldl , fold , or reduce , though there