# SPDX-FileCopyrightText: Stone Tickle <lattis@mochiro.moe>
# SPDX-License-Identifier: GPL-3.0-only

r = range(5)
assert(r[0] == 0)
assert(r[1] == 1)
assert(r[2] == 2)
assert(r[3] == 3)
assert(r[4] == 4)
assert(p(r[-5]) == 0)

assert(range(5, 6)[-1] == 5)
assert(p(range(0, 11, 2)[0]) == 0)
assert(p(range(0, 11, 2)[1]) == 2)
assert(p(range(0, 11, 2)[2]) == 4)
assert(p(range(0, 11, 2)[3]) == 6)
assert(p(range(0, 11, 2)[4]) == 8)
assert(p(range(0, 11, 2)[5]) == 10)
