Holders Celtic will face Raith Rovers in the fifth round of the Scottish Cup after the draw for the last 16 was made.
Rangers will host Queen’s Park in a Glasgow derby, while St Mirren meet Hearts in an all-Premiership tie.
Scott Brown’s Ayr United are at home to his former club Hibernian and Dundee’s reward for their derby win is a tie against Airdrie at Dens Park.
Livingston were drawn at home to face Cove Rangers, while Aberdeen take on Dunfermline at Pittodrie, and St Johnstone will be at home to Hamilton.
How they got there
Hearts were the first team to book their place in the fifth round with a 4-1 win over Brechin on Friday night.
Saturday’s ties saw Airdrie progress with a 5-1 win at Dumbarton, Cove Rangers defeat Forfar 2-0 at home and Dunfermline Athletic cruise to a 3-0 win over Stenhousemuir.
St Johnstone won a tight all-Premiership tie against Motherwell 1-0, while Queens Park needed extra time to defeat Montrose 3-2. Ross County’s home game against Livingston was another to go to extra time and it was David Martindale’s Lions who came out on top.
Hibernian saw off Clydebank with a 3-0 win at Easter Road, St Mirren won 3-0 at Queen of the South and Hamilton were 3-1 victors over Musselburgh. Aberdeen got a much-needed 3-0 win at Elgin City, Ayr United hammered Broxburn Athletic 8-0 and holders Celtic marched on with a 2-1 win at home to Kilmarnock.
Sunday’s ties saw Raith Rovers beat Falkirk 2-1 after extra time, while Rangers cruised to a 5-0 win over Fraserburgh.
Dundee were the last side to book their place in the draw, as Simon Murray scored to give his side a 1-0 win over Dundee United in Monday’s derby.
Scottish Cup draw in full
Ayr United v Hibernian
Celtic v Raith Rovers
St Mirren v Hearts
Rangers v Queen’s Park
Livingston v Cove Rangers
Aberdeen v Dunfermline
St Johnstone v Hamilton Academical
Dundee v Airdrieonians
All fifth round ties are scheduled to be played on the weekend of February 8.
Follow STV News on WhatsApp
Scan the QR code on your mobile device for all the latest news from around the country