On 9/26/18 7:28 PM, Curt Tilmes wrote:


On Wed, Sep 26, 2018 at 10:19 PM ToddAndMargo <toddandma...@zoho.com <mailto:toddandma...@zoho.com>> wrote:


    My understanding it that if it uses "--Positinal"
    I can use []


Yes.  Everything described here: https://docs.perl6.org/type/Positional

You can also call .elems to see how many elements there are and .AT-POS() (same as []), .EXISTS-POS() to see if an element exists, etc.

"a b c d e".words.elems
5
"a b c d e".words(3).elems
3
"a b c d e".words.AT-POS(2)
c
"a b c d e".words(3).EXISTS-POS(4)
False

Curt

Thank you!

Reply via email to