You have holes on the surface of an old table, each hole's position given in an integer array arr. You want to cover all these holes using exactly two boards of the same positive integer length. If a board of length is placed at position , it will cover any hole whose position is in the range inclusively.
Ask AI Assistant

Ask AI Assistant
Ask me anything about this coding question!
Test Cases
Input
Output
Expected