in case 1 you can solve the problems of assigning boys rooms and girls rooms separately, then multiply the numbers to get the result. Both subproblem are the same actually so the answer is something squared. Assume $n$ even otherwise there's no solution: in that case line the boys up and for the first pick one of the $n-1$ boys, for the second pick one of the $n-3$ remaining and so on. Do the same with girls. Then you get $[(n-1)(n-3)\cdots]^2$ ways.
In the second case line the boys and pair girls up with them, then count the number of permutations of girls: $n!$