Forest is nothing but disjoint union of trees.
So no of edges in 'k' components of 'v' vertices is nothing but $\sum_{i=1}^k v_i -1$,
where $v_i$ is the no. of vertices in the $i^{th}$ component.
$\sum_{i=1}^k v_i = v$.
So, $\sum_{i=1}^k v_i - 1 = v - k$