The sum of two numbers is 24. The difference of the numbers is 16. Find the numbers.

This is what I have so far:
x+y-16=24

Nevermind about this question, I solved it myself.

first we solve this with variables x and y

x+y=24
x-y=16

now, you add the two equations

2x, the y cancelled

24+16 = 40

2x= 40
now you divide both sides by 2

x= 20

now, using the equation x +y=24

20 +y = 24
y= 24- 20=4

checking our answers

x+y=24
20+4=24
now, x-y=16
20-4=16

Sum of two numbers is 100 and their difference is 50 the ratio between the two numbers is

To find the two numbers, let's assign variables to them. Let's say the first number is x and the second number is y.

From the given information, we can set up two equations:

1. The sum of two numbers is 24:
x + y = 24

2. The difference of the numbers is 16:
x - y = 16

To solve these equations, we can use the method of substitution or elimination. Let's use the method of substitution for this example.

From equation 2, we can express x in terms of y:
x = y + 16

Now, we substitute this expression for x in equation 1:
(y + 16) + y = 24

Simplifying:
2y + 16 = 24

Subtracting 16 from both sides:
2y = 8

Dividing both sides by 2:
y = 4

Now that we have the value of y, we can substitute it back into one of the original equations to find the value of x. Let's use equation 1:
x + 4 = 24

Subtracting 4 from both sides:
x = 20

Therefore, the two numbers are x = 20 and y = 4.