At the end of the first day, Bangladesh still trail Sri Lanka by 166 runs with just six wickets in hand. "It is common sense but cricket is a amusing game", Silva told reporters.
The touring Sri Lankans are now in pole position to win the Test match, having posted 222 in their first innings, before bowling the hosts out for a meagre 110.
"We bowled them out for 100 and we wanted to get more than 300-plus runs actually".
Bangladesh allrounder Mehidy Hasan believed his side could pull off a record chase.
"We have the belief".
Earlier Bangladesh, who started the day on 56-4 in response to Sri Lanka s 222, faltered against Dananjaya s mystery spin that rattled the hosts middle and lower-order.
"They", Mehidy said, "put the ball in right areas more consistently that we do".
Razzak, who played last of his previous 12 Tests in 2014, struck in his third over when he dragged opener Dimuth Karunaratne, on three, out of his crease for a stumping by wicketkeeper Liton Das.
He hit nine fours in his nearly chance-less knock, facing 94 balls as his teammates struggled in the middle.
Earlier, Bangladesh resumed their first innings on 56-4 and ended on 110 after collapsing suddenly, losing 5-3 in three overs to give Sri Lanka a big lead.
Sri Lankan wicket-keeper Niroshan Dickwella had a moment to forget during their Test match against Bangladesh as he dropped one can only be described as a clanger.
Dhananjaya de Silva managed to make 28 runs before he was clean bowled by Taijul Islam, while Danushka Gunathilaka made 17.
Imrul Kayes' resistance was broken by Perera, who took him out leg before wicket on 19.
Sri Lanka were in trouble at 105 for four at the interval after captain Dinesh Chandimal elected to bat in the final Test of the series at the Sher-e-Bangla National Stadium. Miraz, the top scorer for the hosts, was not out on 38.
Dananjaya (3-20) dented Bangladesh's hope when he removed Mahmdullah and Sabbir Rahman (0) in a span of four deliveries and in his next over, he had Abdur Razzak (1) caught off his own bowling.