puts() quirk

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

Dear List

I don't know if anyone's noticed this before ... maybe it's old news.

	sequence a
	sequence b

	a = { 'c', 'a', 't', 0, 0, 0 }
	b = "dog"

	puts( 1, a & "\n"  )
	puts( 1, b )

This outputs
	catdog
Rather than
	cat
	dog
As one might expect.

Indeed, if one combines the puts() into one, e.g.
	puts( 1, a & "\n" & b )
then the program outputs
	cat

Weird.

Bruce.
(Windows 2000 Advanced Server, Euphoria 2.4 beta, DOS32 script in a 
CMD.EXE window)

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

Search



Quick Links

User menu

Not signed in.

Misc Menu