A and B can do a piece of work in 12 days. They started to work together but A left after a few days. If B alone worked for 20 days, the whole work was finished in 24 days. How long would A take to complete the work???

question is really confusing :/

1/a + 1/b = 1/12

So, if A left after n days, A&B did n/12 of the work.

20/b = 1 - n/12
240 = 12b - nb
b = 240/(12-n)

so,
1/a + (12-n)/240 = 1/12
240 + (12-n)a = 20a
a = 240/(8+n)

I agree the question is confusing. The exact conditions seem ambiguous.

To solve this problem, let's break it down step by step:

1. Let's assume that A can complete the work in x days. This means that in a single day, A will complete 1/x of the work.
Similarly, B will complete the work in y days, so in a single day, B will complete 1/y of the work.

2. Working together, A and B can complete 1/12th of the work in a single day. Therefore, we can write the equation:
1/x + 1/y = 1/12

3. Now, A and B work together on the task for a few days. Let's assume A worked for d days and B worked for 24 days in total.
In d days, A would have completed d/x of the work, and in 24 days, B would have completed 24/y of the work.

4. Since they were working together, the total work completed in d days is given by (d/x + 24/y).
According to the given information, this total work completed in d days is equal to 1 - meaning the remaining work is 1 - (d/x + 24/y).

5. We know that A and B working together can complete 1/12th of the work in a single day.
So, we can write the equation: (1/12) * (24 - d) = 1 - (d/x + 24/y)

6. Rearranging this equation, we get: 24 - d = 12 - 12 (d/x + 24/y)

7. Simplifying further, we have: 12 (d/x + 24/y) = 12 - 24 + d
which becomes: 12 (d/x + 24/y) = d - 12

8. Multiplying through by xy, we get: 12dy + 288x = dx - 12xy

9. Rearranging this equation, we can make it easier to solve for x: dx + 12xy = 12dy + 288x

10. Factoring out x, we have: x(d+288) = 12dy

11. Solving for x, we get: x = 12dy / (d + 288)

Using these steps, you can now calculate the value of x, which represents the number of days it would take for A to complete the work on their own.