The category, select element begins at index 1, where the corresponding option is "Select Category".  That means the first, actual category begins at index 2, and because Perl arrays are 0-indexed we must subtract 2 from each category's id to get its index in `@_CATEGORIES`.