The best way to do this sort of question is to draw a nice clear graph of x vs t. On this graph, put t where you would normally put x (left-right direction), and put x where you would normally put y (up-down direction).
You'll find that this graph is a parabola concaving up (i.e. smiley shape), and by factorising you find that it has roots at t=1 & t=4. You can find it's vertex to be at t=2.5 (the average of 1 & 4), and therefore x= -2.25. This is the minumum point of the parabola (i.e. the furthest down it travels).
-from t=0 to t=2.5 it has travelled 6.25m (going from x=4 to x=-2.25)
-from t=2.5 to t=4 it has travelled 2.25m (going from x=-2.25 to x=0)
{note that I've split it up where the minumum pt of the parabola is i.e. at t=2.5 You don't need to split it up any further}
so the total DISTANCE travelled = 6.25+2.25 = 8.5m