Re: Can .substring be made to handle an empty result?

2021-04-04 Thread G. Branden Robinson
Hi, Jim! At 2021-03-26T15:20:11-0700, Jim Avera wrote: > I'm trying to use .substring to remove the first character of a > string, leaving behind whatever follows, even if that is nothing (i.e. > the string had only one character). > >   .substring str 1 > > or > >   .length n2 "\*[str] >   .nr

Can .substring be made to handle an empty result?

2021-03-26 Thread Jim Avera
I'm trying to use .substring to remove the first character of a string, leaving behind whatever follows, even if that is nothing (i.e. the string had only one character).   .substring str 1 or   .length n2 "\*[str]   .nr n2 -1   .substring str 1 \n[n2] (if n2 is omitted, it appears to defaul