There were some tarts in a box 5 8 of the tarts were chocolate tarts and the rest were vanilla tarts after mrs cheng sold 1 3 of the vanilla tarts there were 30 vanilla tarts left in the box how many tarts were there altogether in the box at first?

Let's assume that the total number of tarts at first is represented by x.

The number of chocolate tarts in the box is 5/8 of x, which is (5/8)x.
The number of vanilla tarts in the box is x - (5/8)x, which simplifies to (3/8)x.
After Mrs. Cheng sold 1/3 of the vanilla tarts, there were 30 left, so (2/3)(3/8)x = 30.
Multiplying both sides by (3/2) gives (3/8)x = 45.
Dividing both sides by (3/8) gives x = 45/(3/8), which simplifies to x = 45 * (8/3), which is x = 120.
So, there were 120 tarts altogether in the box at first. Answer: \boxed{120}.

To find out the total number of tarts in the box at first, we can follow the given information:

1. Let's assume the total number of tarts in the box at first is represented by 'x'.
2. Out of the x tarts, 5/8 were chocolate tarts. So, the number of chocolate tarts is (5/8)x.
3. The remaining tarts in the box would be the vanilla tarts. So, the number of vanilla tarts is x - (5/8)x = (3/8)x.
4. After Mrs. Cheng sold 1/3 of the vanilla tarts, there were 30 vanilla tarts left. So, (2/3) * (3/8)x = 30.
5. Solving the equation, (2/3) * (3/8)x = 30, we can find the value of x.

Let's solve the equation step-by-step to find the value of x:

Step 1: Multiply (2/3) and (3/8) to get (2/8) or (1/4).
Step 2: Rewrite the equation as (1/4)*x = 30.
Step 3: Multiply both sides of the equation by 4 to isolate x.
(1/4)*x * 4 = 30 * 4,
x = 120.

Therefore, there were 120 tarts altogether in the box at first.

To find the total number of tarts in the box at first, we can follow these steps:

Step 1: Calculate the number of vanilla tarts sold by Mrs. Cheng.
Mrs. Cheng sold 1/3 of the vanilla tarts, and there were 30 left. So, we can calculate the number of vanilla tarts sold by multiplying 30 by 3/1 (reciprocal of 1/3).
Vanilla tarts sold = 30 * (3/1) = 90.

Step 2: Calculate the number of chocolate tarts in the box.
We are given that 5/8 of the tarts were chocolate tarts. So, let's calculate the number of chocolate tarts by adding the number of vanilla tarts sold to the remaining 30 vanilla tarts and subtracting it from the total number of tarts.
Number of chocolate tarts = Total tarts - (Vanilla tarts sold + Vanilla tarts remaining)
Number of chocolate tarts = Total tarts - (90 + 30).

Step 3: Find the total number of tarts.
Since the number of chocolate tarts is 5/8 of the total tarts, we can equate it to (5/8) * Total tarts. Then, we can solve for the total number of tarts.
(5/8) * Total tarts = Number of chocolate tarts.
Total tarts = (Number of chocolate tarts * 8) / 5.

Now, let's calculate the total number of tarts altogether using the information provided:

Total tarts = (Number of chocolate tarts * 8) / 5
Total tarts = ((Total tarts - (90 + 30)) * 8) / 5
Simplifying the equation:
5 * Total tarts = (Total tarts - 120) * 8
5 * Total tarts = 8 * Total tarts - 960
960 = 8 * Total tarts - 5 * Total tarts
960 = 3 * Total tarts
Total tarts = 960 / 3
Total tarts = 320

Therefore, there were 320 tarts altogether in the box at first.