Coding in Python - floating number in series

You could try:

 def print_hi():
        for i in range(0, 41, 1):
            if i == 10 or i == 20:
                continue
            print(i / 10.0)

Because Python's range() can only do integers, so we did a trick.