# Arup Guha
# 6/2/2026
# List Practice

# Empty list.
items = []

# How to add to end of list.
for i in range(10):
    items.append(3*i)

# How python prints a whole list.
print(items)

# Each item on a line by itself.
# len returns length of list.
for i in range(len(items)):
    print(items[i])

# Iterator loop.
for mine in items:
    print(mine)

# Test reverse.
items.reverse()
print(items)

# Returns a list of length five, which is the elements in items
# from index 3 through index 7, so the right endpoint is exclusive.
newlist = items[3:8]
print(newlist)

# Goes from 0 to 3.
newlist2 = items[:4]
print(newlist2)

# Goes from 3 to end.
newlist3 = items[3:]
print(newlist3)
