Hello, I need help writing an explicit formula for nth term

The given arithmetic sequence:
-3, -10, -17, -24, .......
The common difference, d = -10 - (-3) = -10 + 3
d = -7
The first term, a = -3
Let the number of terms be n
The nth term of an arithmetic sequence is given as:
[tex]\begin{gathered} a_n=a+(n-1)d \\ \end{gathered}[/tex]Substitute a = -3 and d = -7 into the equation
[tex]\begin{gathered} a_n=-3+(n-1)(-7) \\ \\ a_n=-3-7n+7 \\ \\ a_n=-3+7-7n \\ \\ a_n=4-7n \end{gathered}[/tex]The explicit formula for the nth term is:
[tex]a_n=4-7n[/tex]