Alright, so if the red jelly beans are x and the yellow jelly beans are y, then (3/4)y=x. In addition, (4/5)(y-6)=x-3. Plugging 3y/4 into the equation, we get 4y/5-24/5=3y/4-3. Adding 24/5 to both sides and subtracting 3y/4 from both, we get 4y/5-3y/4=24/5-3. Multiplying 4y/5 by 4/4, 3y/4 by 5/5, etc to get a denominator of 20 we get 16y/20-15y/20=96/20-60/20. Multiplying both sides by 20, we get 16y-15y=96-60 and y=36
The ratio of red jelly beans to yellow jelly beans in a dish is 3:4. If Greg eats 3 red jelly beans and 6 yellow ones, the ratio is 4:5. How many yellow jelly beans were originally in the dish?