Re: array(0, {800,600}) is easier.
- Posted by "Lucius L. Hilley III" <lhilley at CDC.NET> May 13, 2000
- 559 views
In the words of the great Homer Simpson. "DOH!" It should have been repeat(repeat(0,8),10)--No reversal Similarly it should be. function array(integer filler, sequence dimensions) object x x = filler for A = 1 to length(dimensions) do x = repeat(x, dimensions[A])--corrected before sent to listserv end for return x end function The mixed up version of the routine, that I cooked up the first time, properly served my purposes. I guess that is why I didn't notice I had done it all wrong. Bells should have gone off when I tried to reverse it because I knew I was handling the data backwards and then it would not work. :) ------Thanks again Dan. Lucius L. Hilley III lhilley at cdc.net +--------------+--------------+ | ICQ: 9638898 | AIM: LLHIII | +--------------+--------------+ | http://www.cdc.net/~lhilley | +-----------------------------+ ----- Original Message ----- From: "Dan B Moyer" <DANMOYER at prodigy.net> To: "Euphoria Programming for MS-DOS" <EUPHORIA at LISTSERV.MUOHIO.EDU> Sent: Thursday, May 11, 2000 7:27 AM Subject: Re: array(0, {800,600}) is easier. > Lucius, > > It seems to me that neither your "repeat" example nor your array > function yield the 8x10 array you want. <SNIP> > Dan Moyer >