Let's denote the amount of time they parked (in hours) by \( x \).
For Samuel's parking: Samuel paid a flat rate of $17.
For Josie's parking: Josie paid $7 up front and $1 for every hour of parking. Therefore, the total amount paid by Josie can be represented as: \[ \text{Josie's total cost} = 7 + 1 \cdot x = 7 + x \]
Since both Samuel and Josie ended up paying the same amount, we can set up the following equation: \[ 17 = 7 + x \]
Next, we'll solve for \( x \):
- Subtract 7 from both sides: \[ 17 - 7 = x \] \[ 10 = x \]
So, \( x = 10 \) hours.
Now we can find out how much each paid:
- Samuel's cost: $17
- Josie's cost: \[ 7 + x = 7 + 10 = 17 \]
Thus, both Samuel and Josie paid $17.
Putting it all together: Samuel and Josie both ended up paying $ 17 for 10 hours of parking.