I need help bad it’s like son 2 way table stuff

The first one I'll do is Physics because you know the amount of girls and total amount of students. Use the equation x+19=33. Note that x is the amount of boys we are trying to find. All you need to do is simply subtract 19 from both sides to get x alone.
x + 19 = 33
-19 -19
x = 14
For the total that's going up and down, you can do this same process again, but just using x for girls instead of boys. Your equation should look like 47+x=80. Once again, subtract 47 from both sides.
47 + x = 80
-47 -47
x = 33
Now you can find whole row for boys. This equation will be a little longer, but it's still pretty easy. 18+x+14=47 is what we will be using. We first will need to combine like terms (the 18 and 14), then subtract it off from both sides to get x alone.
18 + x + 14 = 47
x + 32 = 47
-32 -32
x = 15
Moving onto the biology column, we'll be using the equation 15+x=21
15 + x = 21
-15 -15
x = 6
Now we can find out the girls column with this equation: x+6+19=33
x + 6 + 19 = 33
x + 25 = 33
-25 -25
x = 8
Lastly, we can find the chemistry column by just adding 18+8 to get 26.
I know this was a little hard to follow along, so here's a picture of it finished: