contestada

“If S = -- [2a + (n − 1)d], find the value of S when n = 42, a = 50, d = −2.”
Can someone please explain, I got the answer from a friend, but still don’t get how to get there (answer is s=378)