[proofplan]
We compute the determinant of $tI_n-A$ directly from the Leibniz formula. The matrix $tI_n-A$ has the same triangular shape as $A$, and its diagonal entries are $t-a_{ii}$. In the Leibniz expansion of a triangular matrix, every non-identity permutation contributes zero, so the determinant is exactly the product of the diagonal entries.
[/proofplan]
[step:Pass from $A$ to the triangular matrix $tI_n-A$]
Let $R:=k[t]$, and regard $tI_n-A$ as a matrix in $M_n(R)$. Define $B=(b_{ij})\in M_n(R)$ by
\begin{align*}
B:=tI_n-A.
\end{align*}
Thus, for each $i,j\in\{1,\dots,n\}$,
\begin{align*}
b_{ij}=t\delta_{ij}-a_{ij},
\end{align*}
where $\delta_{ij}\in k$ denotes the Kronecker delta.
If $A$ is upper triangular, then $a_{ij}=0$ whenever $i>j$. For such $i,j$, also $\delta_{ij}=0$, so $b_{ij}=0$. Hence $B$ is upper triangular. If $A$ is lower triangular, then $a_{ij}=0$ whenever $i<j$, and the same computation gives $b_{ij}=0$ whenever $i<j$. Hence $B$ is lower triangular.
In both cases, the diagonal entries of $B$ are
\begin{align*}
b_{ii}=t-a_{ii}
\end{align*}
for $i\in\{1,\dots,n\}$.
[/step]
[step:Show that only the identity permutation contributes to the determinant]
Let $S_n$ denote the symmetric group of all permutations of $\{1,\dots,n\}$. For $\sigma\in S_n$, let $\operatorname{sgn}(\sigma)\in R$ denote the image in $R=k[t]$ of the integer sign of the permutation $\sigma$. By the Leibniz formula, which defines the determinant over the commutative ring $R$,
\begin{align*}
\det B=\sum_{\sigma\in S_n}\operatorname{sgn}(\sigma)\prod_{i=1}^n b_{i,\sigma(i)}.
\end{align*}
Assume first that $B$ is upper triangular. If a term indexed by $\sigma\in S_n$ is nonzero, then $b_{i,\sigma(i)}\ne 0$ for every $i\in\{1,\dots,n\}$, so upper triangularity forces $\sigma(i)\ge i$ for every $i$. Summing these inequalities gives
\begin{align*}
\sum_{i=1}^n \sigma(i)\ge \sum_{i=1}^n i.
\end{align*}
Since $\sigma$ is a permutation of $\{1,\dots,n\}$, the two sums are equal. Therefore every inequality $\sigma(i)\ge i$ is an equality, so $\sigma(i)=i$ for every $i$. Thus $\sigma=\operatorname{id}$.
Assume now that $B$ is lower triangular. If a term indexed by $\sigma\in S_n$ is nonzero, then lower triangularity forces $\sigma(i)\le i$ for every $i$. Summing gives
\begin{align*}
\sum_{i=1}^n \sigma(i)\le \sum_{i=1}^n i.
\end{align*}
Again the two sums are equal because $\sigma$ is a permutation, so $\sigma(i)=i$ for every $i$. Thus $\sigma=\operatorname{id}$.
Consequently, in either triangular case, the only nonzero term in the Leibniz formula is the term indexed by the identity permutation.
[guided]
Recall that $R=k[t]$ and that $B=(b_{ij})\in M_n(R)$ is the matrix $B=tI_n-A$. The determinant is a sum over all ways of choosing one entry from each row and one entry from each column. The triangular shape makes almost all of those choices impossible: if a chosen entry falls on the zero side of the triangle, the whole product becomes zero.
Let $S_n$ be the group of permutations of $\{1,\dots,n\}$. For $\sigma\in S_n$, let $\operatorname{sgn}(\sigma)\in R$ denote the image in $R$ of the integer sign of $\sigma$. The Leibniz formula, used as the determinant definition in the [polynomial ring](/page/Polynomial%20Ring) $R=k[t]$, says
\begin{align*}
\det B=\sum_{\sigma\in S_n}\operatorname{sgn}(\sigma)\prod_{i=1}^n b_{i,\sigma(i)}.
\end{align*}
Here a permutation $\sigma$ chooses the entry $b_{i,\sigma(i)}$ from row $i$, and the product uses exactly one entry from each column because $\sigma$ is bijective.
Suppose first that $B$ is upper triangular. Then $b_{ij}=0$ whenever $i>j$. Therefore, if
\begin{align*}
\prod_{i=1}^n b_{i,\sigma(i)}
\end{align*}
is nonzero, none of its factors may lie below the diagonal. For every $i\in\{1,\dots,n\}$, this forces $\sigma(i)\ge i$. Summing over $i$ gives
\begin{align*}
\sum_{i=1}^n \sigma(i)\ge \sum_{i=1}^n i.
\end{align*}
But $\sigma$ is a permutation, so the list $\sigma(1),\dots,\sigma(n)$ is just a reordering of $1,\dots,n$. Hence
\begin{align*}
\sum_{i=1}^n \sigma(i)=\sum_{i=1}^n i.
\end{align*}
The only way a finite collection of inequalities $\sigma(i)\ge i$ can have equality after summing is that each individual inequality is equality. Thus $\sigma(i)=i$ for every $i$, so $\sigma=\operatorname{id}$.
We now repeat the argument for the lower triangular case with the inequality reversed. If $B$ is lower triangular, then $b_{ij}=0$ whenever $i<j$. A nonzero determinant term must therefore satisfy $\sigma(i)\le i$ for every $i$. Summing gives
\begin{align*}
\sum_{i=1}^n \sigma(i)\le \sum_{i=1}^n i.
\end{align*}
Since $\sigma$ is still a permutation, the two sums are equal, and therefore every inequality $\sigma(i)\le i$ is equality. Hence $\sigma=\operatorname{id}$.
Thus, whether $B$ is upper triangular or lower triangular, every non-identity permutation contributes a zero product to the determinant expansion.
[/guided]
[/step]
[step:Evaluate the surviving determinant term]
Since only the identity permutation contributes, and $\operatorname{sgn}(\operatorname{id})=1$, the determinant formula reduces to
\begin{align*}
\det B=\prod_{i=1}^n b_{ii}.
\end{align*}
Using $b_{ii}=t-a_{ii}$ for each $i\in\{1,\dots,n\}$, we obtain
\begin{align*}
\det(tI_n-A)=\prod_{i=1}^n(t-a_{ii}).
\end{align*}
By the defining convention $\chi_A(t)=\det(tI_n-A)$, this gives
\begin{align*}
\chi_A(t)=\prod_{i=1}^n(t-a_{ii}).
\end{align*}
This is the desired formula.
[/step]