Problem
Create a function called findIndex, which takes one Rectangle object r, an array of Rectangle objects a, and the length of the array. If r is in a, then return the corresponding index. Otherwise, return -1. Analyze the time complexity of the findIndex function in terms of the length of the array.