Set up the equation first like this, and see if the information provided in both statements are sufficient to solve for the equations.
Time = (Distance/Speed)
1) Time that Mary took to travel 40 miles is - [(y/x)]+[(40-y)/1.25x]
2) Time it would have taken her if she traveled at xmph for entire trip - 40/x
What we're looking for is equation 1 divided by equation 2, or:
3) [(y/x)+[(40-y)/1.25x]]/ (40/x)
Statement 1
Plugging in x=48 into the above equation 3, you get:
[(y/48)+[(40-y)/(1.25)(48)]]/ (40/48)
Even after simplifying this equation, y remains unknown as it does not cancel out. Hence, you cannot find the percentage of time.
Statement 1 is insufficient
Statement 2
Plugging in y=20 into the above equation 3, you get:
[(20/x)+[(40-20)/1.25x]]/ (40/x)
[(25+20)/1.25x]/(40/x)
You take (40/x) in denominator to the top by multiplying it by its reciprical (x/40)
The two x-es cancel each other as one x is now in the top and one at the bottom to get:
(45/50) or 90%.
Note that you do not actually need to find the percentage or to work out the entire thing as this is a data sufficiency question. Once you see that the x-es cancel each other out, you should know that the remaining number is a fraction which can be equated to a percentage, hence, statement 2 is sufficient.