Turn the Other Cheek?

Turn the Other Cheek?

(Matthew 26, 26:52): “Then said Jesus unto him, Put up again thy sword into his place: for all they that take the sword shall perish with the sword.

OR

Luke 22:36:

“But now,” Jesus said, “whoever has a purse or a bag must take it; and whoever does not have a sword must sell his coat and buy oneQuestion: Why would Jesus say sell your coat and buy Sword? To do what? Chop up some Watermelons? If the above is not a contradiction, what is the contradiction then?