P.S. any tips on angle-wrap-respecting code to determine if a supplied angle is inbetween (on the short side) another two supplied angles? Imagine "spinning a bottle" and then checking if the resulting angle is within a certain sector, the sectors not all being equally sized or spaced, so it needs to be a genuine check of "is it between these sector limit angles".
This problem is trickier than simple comparison due to wrapping issue, but still easily solvable by splitting circle in two regions.
Lets say full circle has possible angles from \$0..360\$ (360 being same as 0).
Input is angle \$X\$ and sector from angle \$A\$ to angle \$B\$ (\$A>B\$ or \$A<B\$, i.e. \$10..350\$ (340 degree sector) is different from \$350..10\$ (20 degree sector))
Split circle in to two regions - \$0..180\$ and \$180..360\$. Based on \$X\$, select \$0..180\$ or \$180..360\$ region. Recalculate \$A..B\$ sector coverage in this region, to get \$A'..B'\$ sector with condition \$A'<B'\$. Then comparison \$A'<X<B'\$ gives the answer.