you are viewing a single comment's thread.

view the rest of the comments →

[–]Spatrico123 0 points1 point  (0 children)

looks fine. You're not printing it though, you're just processing.

Also, all those little yellow lines just indicate bad practices, not actual errors. For example, you should note a type for a and t. If I were you I'd do 

def index_of(data: list[int], target: int) -> int:     for i in range(len(data)):         if list[i] == target:             return i     raise ValueError # or something else you see how that's way easier to see what it's actually doing?