Minimum Cuts to Divide a Circle

From LeetCode. A circle can be divided by two kinds of straight cuts. A diameter cut runs through the center and touches the circumference at two opposite points, producing 2 equal sectors. A radius cut runs from the center to a single point on the circumference, producing 1 sector. Given an integer n, return the minimum number of cuts needed to divide the circle into n equal sectors. The input is provided as a single-element array [n].

Examples
Input: [1]
Output: 0
Hints

Minimum Cuts to Divide a Circle

**From LeetCode.** A circle can be divided by two kinds of straight cuts. A **diameter** cut runs through the center and touches the circumference at two opposite points, producing 2 equal sectors. A **radius** cut runs from the center to a single point on the circumference, producing 1 sector. Given an integer `n`, return the minimum number of cuts needed to divide the circle into `n` equal sectors. The input is provided as a single-element array `[n]`.