Found a function today that has a simple ‘status’ integer param which can be any value or combination of 1-5 passed in the following ways
getTransactions(1);
getTransactions(array(1, 2, 3, 4, 5));
getTransactions(1, 2, 3, 4, 5);
I think this nicely demonstrates how not having a clear specification from the start, and not being mindful of how a function may be used in the future can greatly complicate code.