RE: if statement not working
- Posted by bensler at mail.com Mar 22, 2002
- 456 views
Kat wrote: > On 22 Mar 2002, at 23:24, Derek Parnell wrote: > > > > > ----- Original Message ----- > > From: "Graeme" <graemeburke at hotmail.com> > > To: "EUforum" <EUforum at topica.com> > > Sent: Friday, March 22, 2002 7:20 PM > > Subject: Re: if statement not working > > > > > > > >I just tripped against this stupid restriction again last night. I've > > > written a function called > > > >begins() to help me out, but it ain't pretty. > > > > > > > > if begins(s, t) then ... > > > > > > > >I originally wrote: > > > > > > > > if equal(s[1..length(t)], t) then ... > > > > > > > >but this fails whenever s is shorter than t. > > > > > > > > > Yeah, and I hate having to press enter at the end of the > > > line, it really annoys me. Rob can you fix this or I want my > > > money back..... > > > > > > > Thanks for those encouraging words. I feel much better now that I > > realise I must > > not desecrate the temple of Euphoria. > > > > > But seriously, having the interpreter return a valid result > > > from accessing non-existant data is just way stupid. > > > > > > > Graeme, you are absolutely correct. > > So if i were to ask you to return all 100K bytes of this email, you'd > land in a > mental institution? Eu would, figuratively speaking. > > Kat > That's not natural behaviour. When you tell me to to return 100kb of this file, I'll tell you it's not 100kb. I won't give you the file padded with.. what SHOULD it be padded with? If you told me to give you 100kb of this file, or whatever I can if it's not that big, then I would give you about 10kb of data. If you told me I MUST return 100kb from this file, I would then proceed to ask what I should append to the data. Chris