Final answer:
Gina walked a total of 166 feet in the gym.
Step-by-step explanation:
To calculate the total distance Gina walked, we can break it down into different parts:
1. Upper body machines: Gina walked from machine 6 to machine 7, then from machine 7 to machine 8, and so on. There are 6 upper body machines, and each machine is 8 feet apart, so the total distance for the upper body machines is 6 machines * 8 feet = 48 feet.
2. Lower body machines: Gina walked from machine 6 to machine 5, then from machine 5 to machine 4, and so on. There are 6 lower body machines, and each machine is 8 feet apart, so the total distance for the lower body machines is 6 machines * 8 feet = 48 feet.
3. Walking to the mat after every 3 lower body machines: Gina walked to the mat that was 20 feet past machine 1 after every 3 lower body machines. She did this 2 times, so the total distance for walking to the mat is 2 times * 20 feet = 40 feet.
4. Walking to the wall after every 3 upper body machines: Gina walked to the wall that was 30 feet past machine 12 after every 3 upper body machines. She did this 1 time, so the total distance for walking to the wall is 1 time * 30 feet = 30 feet.
Adding all these distances together, Gina walked a total of 48 feet + 48 feet + 40 feet + 30 feet = 166 feet.