Pakistan have set themselves up to pluck a victory out of the first Test against the West Indies at Sabina Park despite a huge amount lost overs.
The visitors moved to 407 all out from their overnight position of 201/4 with skipper Misbah-ul-Haq top scoring.
Misbah was agonizingly left stranded on 99 not out as he ran out of partners having gutsed it out for 223 balls.
Pakistan lost just Asad Shafiq (22) in the morning session with Sarfraz Ahmed joining the skipper and together moving they moved the score to 322/5 by lunch leading by 36 runs.
Sarfraz (54) fell shortly after the break having out on 98 with Misbah who then toughed it out with the tail until the fall of number 11 Mohammad Abbas (1) prompted the tea break to be taken.
The final session of the day belonged to Pakistan's Yasir Shah with the spinner claiming four scalps in nine overs to have the West Indies reeling.
Yasir bowled opener Kraigg Brathwaite (14) with his first ball with the right hander playing back to one that skidded on and clattered into his stumps.
Shimron Hetmeyer (20) put on fifty with Kieron Powell before he met the same fate as Brathwaite being bowled by Yasir as the leggie got one to rip out of the rough.
Shai Hope (6) used a desperate review but it couldn't save him as Yasir had trapped him dead in front.
Yasir would remove Powell (49) in the final over of the day leaving the West Indies 93 for 4 at the close still 28 runs adrift of making Pakistan bat again.
Yasir ended the day with figures of 4 for 33 from his nine overs.