Implement a function to detect and return the first duplicate item in a list of inventory IDs.
You are practicing as a guest. Sign up free to get your answer graded with AI feedback. Your draft stays right here.