H6 H8 HJ HA <--- ♥6 is 4th best. Note partner didn't lead A or K or Q of ♦
This suggest that partner lacks KQT, KQJ. QJT, AKJ, of diamonds. We have seen 4 of declearer's points
S4 S7 SK SA <<--- declearer must have ♠Q or he would have stiff, that is 6 pts
D6 DA D7 D8 <<-- declearer's diamond ACE probably means he has ♦Q too, or partner would have lead one... That is 6 more ponts.. for total of 12 outside of clubs.
SQ D2 S2 S5 <<==
D3 DT H4 D5 <<== ♦Ten suggest partner is KJTxx solidifying guess on ♦Q
H7 S3 H2 H3 <== higher heart. Partner is 1-4-5-3, declearer 2-3-4-4
SJ S6 H5 HT <<== partner is feeling the pain on trumps,
S9 ST D4 HK <<== declarer must notice.. he knows you have ♥Q
If declarer has both club honors (King and queen), that gives him 17 hcp and rest of tricks. If he has just the queen, he has to hook your partner. But if he has Kxxx he has to hook your partner. But if he has KTxx he has a two way finessee. But he can't be certain as to who to finesee... At this point if your parnter was 1-4-6-2, the odds would favor finessing you for the queen (which you can see is the wrong play for him). If your partner is 1-4-5-3, the odds favor finessing your partner.
So what has this to do with discovery? IF you lead your diamnd, north will ruff, and get complete count of the hand. HE will know your partner started with 5 diamnonds, and hence 3 clubs. But if you exit your heart, he will not discover for certain your distribution.
BTW, if a GOOD player exits with a diamond here, play to drop the Queen offsides doubleton, because if they are helping you get count it is for a reason... and if you are really good, as a defender, and you know they think this way, you can try a double cross by exiting with a diamond to help them count when having 2 small clubs... but then.. if they know that your know... oh heck....good thing most don't play that well as you could spend the whole day trying to figure out how good your good player thinks you are.
East exited a diamond, after whihc declarer played west correctly for teh queen.

Help

West North East South
- Pass Pass 1NT
Pass 2♥! Pass 2♠
3♦ 4♠ Pass Pass
Pass
1NT = 15 to 17 hcp.