1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Small enhancement to @WORD

Discussion in 'Suggestions' started by vefatica, Sep 16, 2017.

  1. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,939
    Likes Received:
    30
    Let @WORD[n-,string] return all words from the nth one to the end.

    As it is now, that syntax is accepted, but does something peculiar, giving n+1 words starting at word n.
    Code:
    v:\> echo %@word[1-,a b c d e f g h i]
    b c
    
    v:\> echo %@word[2-,a b c d e f g h i]
    c d e
    
    v:\> echo %@word[3-,a b c d e f g h i]
    d e f g
    
     

Share This Page