First Division Raith Rovers overcame Highland League opponents Wick Academy in the Ramsdens Cup.
Brian Graham converted Grant Anderson's left-wing cross to open the scoring for the visitors on six minutes but Wick levelled after the break when Luckasz Geruzel drilled home.
David Allan turned in Wick's second equaliser after Douglas Hill's header had put Raith ahead again.
However, Raith finally claimed victory through goals from Anderson and Pat Clark.
Wick Academy: Gray, Cunningham, Michael Steven, Farquhar (Ross 82), Ross Allan, Manson (Weir 86), Shearer, Sam Mackay, Geruzel, David Allan, MacAdie. Subs Not Used: More, Sinclair, McKiddie.
Goals: Geruzel 51, David Allan 61.
Raith: McGurn, Thomson, Murray, Hill (Ellis 76), Malowne, Grant Anderson (Callachan 85), Stuart Anderson, Walker, Hamill, Brian Graham, Clarke. Subs Not Used: Laidlaw, Spence, Donaldson.
Booked: Stuart Anderson, Hill.
Goals: Brian Graham 39, Hill 57, Grant Anderson 71, Clarke 83.
Ref: David Somers