Raith Rovers claimed a 3-2 win over Livingston after a scintillating final 10 minutes at The City Stadium.
Rovers took the lead after 20 minutes when Grant Anderson rifled in a shot from the right-hand side of the penalty area past Andrew McNeil in the Livingston goal.
Livingston were awarded a penalty after 43 minutes when Laurence Ellis was judged to have handled in the box. Liam Fox stepped up and smashed his spot kick into the top right corner.
Raith had the better of the early second half chances, with McNeil pulling off a string of saves notably stopping Joseph Cardle's close range effort shortly after the hour.
Rovers restored their advantage with 10 minutes remaining. Brian Graham managed to lose Paul Watson at the far post, heading Patrick Clarke's cross back into the bottom-right corner.
Iain Russell fired Livingston level with a close range effort following a goalmouth scramble.
But no sooner had the hosts drawn level they found themselves behind again. A devastating error from McNeil allowed Graham in to put away his second of the game and end Raith's season on a high.