At first glance, this does seem perplexing. From reading the texts, it is clear these are two accounts of the same situation; and one need not be a great mathematician to know that 600 shekels of gold is not the same price as 50 shekels of silver. Has the questioner found a contradiction?
There’s a subtle difference in the two accounts, which, if we miss it, will lead to confusion. In 2 Samuel 24, the focus is on the threshing floor and the oxen (v 21, 24). David paid 50 shekels of silver for them. However, in 1 Chronicles 21, the scope of the purchase is not the threshing floor alone. There, David is said to have asked for “…the place of this threshing floor…” (v 22)
The threshing floor and oxen were bought for 50 shekels of silver, but the entire property (the place of the threshing floor) was sold to David at a much larger cost, 600 shekels of gold.
It is worth noting, the land in question (Mt. Moriah), which then belonged to a Jebusite, would become the eventual location for the temple of God in Jerusalem (see JFB)
There is no contradiction.
A response to 1001 Bible Contradictions.