Re: New rtrim()
- Posted by Jiri Babor <jbabor at PARADISE.NET.NZ> Sep 13, 2001
- 415 views
Colin, Igor's unattributed brilliant idea *is* my version. Pity I did not copyright the bloody thing as seems to be the trend these days. But then I do not really care at all, I just hate confusion... jiri ----- Original Message ----- From: <cetaylor at compuserve.com> To: "EUforum" <EUforum at topica.com> Subject: RE: New rtrim() > > Igor, > > Thanks for the suggestion. I tried it in putsxy.e and didn't see any > improvement in performance, so for the moment I'll stick with Jiri's > original version. > > Colin Taylor > > > Igor Kachan wrote: > > Dear Eu users, > > > > There is the rtrim() function in > > the putsxy.e lib. > > > > This function removes zeros from > > the end of a sequence. > > > > New rtrim_() function makes the > > same thing about 30% faster > > and is more simple. > > > > -- > > function rtrim_(sequence s) > > for i=length(s) to 1 by -1 do > > if s[i] then > > return s[1..i] end if end for > > return {} > > end function > > -- > > > > Use it please if you need such a function. > > > > Regards, > > Igor Kachan > > kinz at peterlink.ru > > > > > >