First, let's define a few varibles.
x = # of miles
y = # of days
z = total cost
Now, let's create our expression
z = $23.95y + $0.33x
Let's plug the numbers from our problem into our equation.
$150 = $23.95(2) + $0.33x
Simplify the right side
$150 = $47.9 + $0.33x
Subtract $47.9 from both sides
$102.1 = $0.33x
Divide both sides by $0.33
309 miles = x
Note, I rounded my answer down to the nearest whole number.