Any basic group theory or abstract algebra textbook should be good for learning about permutations. I don't know what people tend to use these days. In my abstract algebra course we used Contemporary Abstract Algebra by Gallian.
The third line in 5a) on the answer sheet comes from applying the permutation $\sigma$ to the numbers in the second row.
"For the inverse of a permutation: since the permutation is cycle it means that any random arrangement of the set can be passed of as an inverse? It says interchanging the rows finds inverse but in the second line its random"
This part of your question is a bit confused. Firstly, not every permutation is a cycle, but I'm not sure whether you were saying that (I don't see anything in the linked image about inverses of permutations, so I'm not sure what 'the permutation' would be referring to).
Every permutation has a unique inverse, so the answer to your question is definitely no!
I don't know what you mean by 'but in the second line it's random'.
Here is an example of how to find the inverse of a permutation by interchanging the rows.
If $\sigma = \left(\begin{array}{cccc} 1 & 2 & 3 & 4\\2 & 4 & 1 & 3 \end{array}\right),$ then
$\sigma^{-1} = \left(\begin{array}{cccc} 2 & 4 & 1 & 3\\1 & 2 & 3 & 4 \end{array}\right) =
\left(\begin{array}{cccc} 1 & 2 & 3 & 4\\3 & 1 & 4 & 2 \end{array}\right)$.
So we first interchange the rows, and then rearrange the columns so that the numbers in the top row are in order, as we are accustomed to seeing them. The reason this works is that if $\sigma$ takes $x$ to $y$, then $\sigma^{-1}$ needs to take $y$ back to $x$ in order to invert the permutation. (Check by calculating $\sigma\sigma^{-1}$ and making sure you get the identity!)
Yes, 'id' does refer to the identity, i.e. the permutation that fixes every point.