How can I use concatenation in scheme without spaces
append returns a list, and the evaluator prints the result like (a b c), where spaces are inserted to make the representation clear. If you need
%procedure:+%, you may create a new symbol or use strings instead of symbols.
You're trying to use symbols, which aren't the same thing as strings in Scheme. If you want to have control over your printed output, you should use strings, which are arrays of characters.
> (append '(hello) '(world)) (hello world) > (string-append "hello " "world") "hello world" > (symbol->string 'hello) "hello" > (apply string-append (map symbol->string '(a b c d e f g))) "abcdefg"
jacky brown 7 months
I have a problem with concatenation and spaces in Scheme. The result of the command:
(append '(%procedure:) (list '+) '(%))** //with spaces
%procedure: + % //without spaces
How can I make the same result without space between the lists, so the result will be:
John Clements about 11 yearsAre you trying to produce a symbol, a string, or something else?