let $V$ be a euclidean space. $T:V\to V$ be an orthogonal linear transformation. $W\subset V$ is a $T$-invariant subspace.
I need to prove 2 things:
A. $T\bigl|_W$ is orthogonal
so I said that if $T$ is an orthogonal linear transformation, then it preserves inner products and for every $v,u$ that belong to $V$, $\langle\, Tv,Tu\,\rangle$ = $\langle\, u,v\,\rangle$.
so if $W\subset V$, then for every $w_1, w_2$ belonging to $W$, $\langle\,Tw_1,Tw_2\,\rangle=\langle\, w_1,w_2\,\rangle$.
but it feels wrong, I'm not sure whether it is right.
B. Show that $W^\perp$ is $T$-invariant. which I have no idea.
Your solution to part A is correct.
Regarding proof of part B, we first observe that $\langle v, w \rangle = 0 \implies \langle Tv, Tw \rangle = 0$ for any $v \in W^{\perp}$ and all $w \in W$. Thus, proving $T\vert_W$ surjects is sufficient; and since $V$ is finite-dimensional it suffices to prove that $T\vert_W$ is injective. If we assume for a contradiction that $w_1 \neq w_2 \in W$ have the same image under $T\vert_W$, then $T(w_1 - w_2) = 0$, which implies that $\langle w_1 - w_2, w_1 - w_2 \rangle = \langle 0, 0 \rangle = 0$; a contradiction, since $\langle v, v \rangle = 0$ if and only if $v = 0$. Thus $T \vert_W$ is injective (thus invertible), and so for all $v \in W^{\perp}$, $w \in W$ we can pick $w' = T\vert_W^{-1}w \in W$ such that $Tw' = w$ and say that $\langle Tv, Tw'\rangle = \langle Tv, w \rangle = 0$, thus $Tv \in W^{\perp}$, and so $W^{\perp}$ is $T$-invariant as desired.