Formula for number of divisions required to form x number of cells (Mitosis and Meiosis)
For a male, one primary spermatocyte produces two secondary spermatocytes through meiosis I, which in turn produce two spermatids each through meiosis II. So one primary spermatocyte produces four spermatids. That means that $x$ spermatids are produced after $x/4$ meiotic divisions consisting of once meiosis I and twice meiosis II.

However, we don't count the first cell here because a primary spermatocyte is fundamentally different form a spermatid. So in meiosis, the first cell isn't counted, and four new cells are produced.

In mitosis, we do count the first cell. Note that there are two cells produced form one, so there is only one new cell. Hence we get the formula $x-1$.