Step - loops
loops ยท category: Branches and loops
Within repeat(): yields the current iteration count (of the named loop).
Forms
loops()
loops(arg1: string)
Example
g.v(1).repeat(__.out()).until(__.loops().is(2)).values("name").to_list() // ["ripple", "lop"]