i'm trying to solve this system of equations with 3 variables

5a-b+3c=5
2a+7b-2c=5
4a-5b-7c=-65

i tried to make the first equation like
a=something
so i could substitute it in to the 2nd equation, however i get decimals so it doesnt work
how do i do this problem?

7*Eq1: 35a-7b+21c = 35.

--Eq2: 2a+7b-2c = 5
Sum:---37a+0+19c = 40.

5*Eq2:10a+35b-10c = 25
7*Eq3:28a-35b-49c = -455
Sum : 38a+ 0-59c = -430.

After eliminating b from two Eqs, we have two Eqs with two unknowns:

Eq4: 37a + 19c = 40.
Eq5: 38a - 59c = -430.

-38*Eq4: -38*37a - 722c = -1520.
37*Eq5 : 37*38a - 2183c = -15,910.
Sum :--------0 - 2905c = - 17,430.
C = 6.

In Eq4, replace c with 6:
37a + 19*6 = 40.
37a = 40 - 114 = -74.
a = -2.

In Eq2, replace a, and c with -2 and 6,
respectively:
2*-2 + 7b - 2*6 = 5.
-4 + 7b - 12 = 5
7b = 5 + 16 = 21.
b = 3.

Solution: a = -2, b = 3, c = 6.

To solve a system of equations with three variables, like the one you have, you can use various methods such as substitution, elimination, or matrices. Let's use the method of elimination in this case:

1. Start by writing down all three equations:
5a - b + 3c = 5 (Equation 1)
2a + 7b - 2c = 5 (Equation 2)
4a - 5b - 7c = -65 (Equation 3)

2. The first step is to eliminate one variable from two pairs of equations. Let's eliminate variable 'a'. To do this, multiply Equation 1 by 2 and multiply Equation 2 by 5:
10a - 2b + 6c = 10 (2 * Equation 1)
10a + 35b - 10c = 25 (5 * Equation 2)

3. Subtract Equation 1 from Equation 2 to eliminate the 'a' variable:
10a - 2b + 6c = 10
- (10a + 35b - 10c = 25)
_________________________
-37b + 16c = 15 (Equation 4)

4. Now, let's eliminate 'a' variable from Equation 2 and Equation 3. Multiply Equation 2 by 4 and multiply Equation 3 by 2:
8a + 28b - 8c = 20 (4 * Equation 2)
8a - 10b - 14c = -130 (2 * Equation 3)

5. Subtract Equation 3 from Equation 2 to eliminate the 'a' variable:
8a + 28b - 8c = 20
- (8a - 10b - 14c = -130)
__________________________
38b + 6c = 150 (Equation 5)

6. Now we have two equations with two variables: Equation 4 and Equation 5. We can solve them simultaneously. Multiply Equation 4 by 3 and multiply Equation 5 by 2 to make the coefficient of 'b' in both equations the same (38b):
-111b + 48c = 45 (3 * Equation 4)
76b + 12c = 300 (2 * Equation 5)

7. Add Equation 4 to Equation 5 to eliminate the 'b' variable:
-111b + 48c = 45
+ 76b + 12c = 300
________________________
-35b + 60c = 345 (Equation 6)

8. Now, we have two equations with two variables: Equation 6 and Equation 5. We can solve them simultaneously. Multiply Equation 6 by 12 and multiply Equation 5 by 6 to make the coefficient of 'c' in both equations the same (60c):
-420b + 720c = 4140 (12 * Equation 6)
+ 456b + 72c = 1800 (6 * Equation 5)

9. Add Equation 6 to Equation 5 to eliminate the 'b' variable:
-420b + 720c = 4140
+ 456b + 72c = 1800
________________________
360c = 5940

10. Divide both sides of Equation 6 by 360 to solve for 'c':
c = 5940 / 360
c = 16.5

11. Substitute the value of 'c' back into Equation 5 to solve for 'b':
38b + 6c = 150
38b + 6(16.5) = 150
38b + 99 = 150
38b = 51
b = 51 / 38
b ≈ 1.342

12. Finally, substitute the values of 'b' and 'c' back into Equation 1 (or any other equation) to solve for 'a':
5a - b + 3c = 5
5a - 1.342 + 3(16.5) = 5
5a - 1.342 + 49.5 = 5
5a = -45.158
a = -45.158 / 5
a ≈ -9.032

So the solution to the system of equations is approximately: a ≈ -9.032, b ≈ 1.342, and c ≈ 16.5.