Islamic countries are moving away from the death penalty, so there is obviously some common sense being applied.

Quick question - I'm assuming that in Islam the Koran dictates which crimes should be punishable by the death penalty, so I understand why Islamic countries implement the death penalty (even if I don't agree with it). But why do countries such as the US have the death penalty? Does the bible talk about crimes being punished by death?