There is not a moment to lose
As I stress constantly, counting losers and winners when the dummy first appears is a vital step in accurate declarer-play. An ounce of effort then will save a pound of pain later when you go down in a contract that you should have made. In this example, how should South play in four hearts after West leads the spade queen?
South opened with a textbook vulnerable weak two-bid: a good six-card suit and 6-10 high-card points. North took a shot at game, but if he had used the artificial twono-trump inquiry, South would have rebid three no-trump to show a really good suit. Then North could have passed and had nine top tricks: two spades, six hearts and one club. In four hearts, South has four losers -- one spade, one diamond and two clubs -- and those same nine winners. From where might a 10th trick come? The chance of two club winners is very low. Instead, declarer should hope for a 4-3 diamond break and establish the diamond jack as a trick. However, that requires ruffing three times in hand, so South needs four dummy entries. Given the spade lead has already removed the spade king, these must be the spade ace, both hearts and the club ace. Declarer must work on diamonds immediately.
At trick two, he plays a low diamond from the board. Suppose East wins with the nine and returns his second spade. South wins with the ace, ruffs a diamond, plays a heart to the 10, trumps a diamond, crosses to the heart queen, ruffs a third diamond, and draws trumps. Finally, declarer plays a club to the ace and discards a black-suit loser on the diamond jack.