Dorothy paid $12 for 3 gold coins so each gold coin is worth $12/3 = $<<12/3=4>>4
The Tavern master originally had $20 worth of gold coins which is $20/$4 = <<20/4=5>>5 gold coins
He gave 3 out of 5 gold coins to Dorothy so he now has 5-3 = <<5-3=2>>2 gold coins left
#### 2