← Back to Difficulty Selection
Code Review (Easy): Finding Shifted Logs
Story
Lena found that the internal event logs were appearing out of order because the system often starts displaying entries from the moment a server reboots, pushing the earlier morning logs to the end of the list. Mark requested a helper tool for the dashboard that can pinpoint the exact position of a specific log ID within these shifted sequences. For example, if the logs are listed as 4, 5, 6, 7, 0, 1, 2, searching for ID 0 should return 4, representing its current place in the sequence.
Your Task
Read the story and code, then decide if the code is ready for production or needs improvement.
Hints
What would block an approval? Give me a hint.
Next
Check out Next Topic: Cleaning the Breadcrumbs