getMod

fun <E> List<E>.getMod(index: Int): E(source)

Returns the indexth element of this, wrapping around circularly so that index -1 is equivalent to this.size - 1.