[proofplan]
We verify the defining conditions for a Lie subalgebra. First, the upper triangular and strictly upper triangular matrices are linear subspaces of $\mathfrak{gl}_n(F)$. Then we prove closure under the commutator bracket by checking matrix entries: products of upper triangular matrices are upper triangular, and products of strictly upper triangular matrices are strictly upper triangular. Since the Lie bracket is the difference of two such products, both subspaces are closed under the bracket.
[/proofplan]
[step:Verify that the triangular matrices form linear subspaces]
Let $A=(a_{ij})$ and $B=(b_{ij})$ be elements of $\mathfrak b_n(F)$, and let $\lambda,\mu \in F$. For every pair of indices $i,j \in \{1,\dots,n\}$ with $i>j$,
\begin{align*}
(\lambda A+\mu B)_{ij}=\lambda a_{ij}+\mu b_{ij}=0.
\end{align*}
Thus $\lambda A+\mu B \in \mathfrak b_n(F)$, so $\mathfrak b_n(F)$ is an $F$-linear subspace of $\mathfrak{gl}_n(F)$.
The same argument applies to $\mathfrak n_n(F)$. If $A,B \in \mathfrak n_n(F)$ and $\lambda,\mu \in F$, then for every $i,j \in \{1,\dots,n\}$ with $i \ge j$,
\begin{align*}
(\lambda A+\mu B)_{ij}=\lambda a_{ij}+\mu b_{ij}=0.
\end{align*}
Hence $\lambda A+\mu B \in \mathfrak n_n(F)$, so $\mathfrak n_n(F)$ is an $F$-linear subspace of $\mathfrak{gl}_n(F)$.
[/step]
[step:Show that the commutator of upper triangular matrices is upper triangular]
Let $A=(a_{ij})$ and $B=(b_{ij})$ be elements of $\mathfrak b_n(F)$. We first show that $AB \in \mathfrak b_n(F)$. For indices $i,j \in \{1,\dots,n\}$ with $i>j$, the matrix product formula gives
\begin{align*}
(AB)_{ij}=\sum_{k=1}^{n} a_{ik}b_{kj}.
\end{align*}
Fix $k \in \{1,\dots,n\}$. If $k<i$, then $a_{ik}=0$ because $A$ is upper triangular. If $k \ge i$, then $k>j$, so $b_{kj}=0$ because $B$ is upper triangular. Therefore every summand $a_{ik}b_{kj}$ is zero, and hence $(AB)_{ij}=0$. Thus $AB \in \mathfrak b_n(F)$.
The same argument with $A$ and $B$ interchanged gives $BA \in \mathfrak b_n(F)$. Since $\mathfrak b_n(F)$ is a linear subspace,
\begin{align*}
[A,B]=AB-BA \in \mathfrak b_n(F).
\end{align*}
Therefore $\mathfrak b_n(F)$ is closed under the Lie bracket of $\mathfrak{gl}_n(F)$.
[/step]
[step:Show that the commutator of strictly upper triangular matrices is strictly upper triangular]
Let $A=(a_{ij})$ and $B=(b_{ij})$ be elements of $\mathfrak n_n(F)$. We first prove that $AB \in \mathfrak n_n(F)$. For indices $i,j \in \{1,\dots,n\}$ with $i \ge j$,
\begin{align*}
(AB)_{ij}=\sum_{k=1}^{n} a_{ik}b_{kj}.
\end{align*}
Fix $k \in \{1,\dots,n\}$. If $k \le i$, then $a_{ik}=0$ because $A$ is strictly upper triangular. If $k>i$, then $k>j$, so $b_{kj}=0$ because $B$ is strictly upper triangular. Hence each product $a_{ik}b_{kj}$ is zero, and therefore $(AB)_{ij}=0$. Thus $AB \in \mathfrak n_n(F)$.
Interchanging $A$ and $B$ gives $BA \in \mathfrak n_n(F)$. Since $\mathfrak n_n(F)$ is a linear subspace,
\begin{align*}
[A,B]=AB-BA \in \mathfrak n_n(F).
\end{align*}
Therefore $\mathfrak n_n(F)$ is closed under the Lie bracket of $\mathfrak{gl}_n(F)$.
[/step]
[step:Conclude that both subspaces are Lie subalgebras]
A Lie subalgebra of $\mathfrak{gl}_n(F)$ is an $F$-linear subspace closed under the Lie bracket inherited from $\mathfrak{gl}_n(F)$. The preceding steps show that $\mathfrak b_n(F)$ and $\mathfrak n_n(F)$ are $F$-linear subspaces and are each closed under the bracket
\begin{align*}
[A,B]=AB-BA.
\end{align*}
Hence $\mathfrak b_n(F)$ and $\mathfrak n_n(F)$ are Lie subalgebras of $\mathfrak{gl}_n(F)$.
[/step]