Re: DAHH another question

new topic     » goto parent     » topic index » view thread      » older message » newer message

At 01:23 PM 5/13/99 -0400, you wrote:
>I have a sequence {a,b,c}
>
>-- how do i append or concantenate two zeros to it
>
>to get this result {a,b,c,0,0}

Doesn't '&' accomplish this?

--proof positive program
sequence x, z, new
atom y

x = {1,2,3}
y = 0
z = {0,0}

? x & y          -- prints {1,2,3,0}
? x & z          -- prints {1,2,3,0,0}
? append(x, y)   -- prints {1,2,3,0}
? append(x, z)   -- prints {1,2,3,{0,0}}

Don't use append when you're appending a sequence... otherwise, you'll get
what you see. smile

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu