What is the meaning of Matthew 12:9-12?

9 And when he was departed thence, he went into their synagogue: 10 And, behold, there was a man which had his hand withered. And they asked him, saying, Is it lawful to heal on the sabbath days? that they might accuse him. 11 And he said unto them, What man shall there be among you, that shall have one sheep, and if it fall into a pit on the sabbath day, will he not lay hold on it, and lift it out? 12 How much then is a man better than a sheep? Wherefore it is lawful to do well on the sabbath days. (Matthew 12:9-12 KJV)

William Burkitt’s Commentary

Here we have another dispute betwixt our Saviour and the Pharisees concerning the sabbath; whether it be a breach of that day, mercifully to heal a person having a withered hand? Christ confutes them from their own practice, telling the Pharisees, that they themselves judged it lawful to help out a sheep, or an ox, if fallen into a pit on that day: how much more ought the life of a man to be preferred!

Here we may remark, how inveterate a malice the Pharisees had against our Saviour: when they could find no crime to charge him with, they blame him for working a merciful and miraculous cure upon the sabbath-day. When envy and malice (which are evermore quick-sighted) can find no occasion of quarrel, they will invent one, against the innocent.