Question
For what is Karet, for what did the Sanhedrin give the death penalty, and for what did they give 40 lashes?
Answer
The beginning of Mishna, Masechet Kritut (1, 1) mentions the 36 sins deserving of Karet. The Rambam, Mishneh Torah, Hilchot Sanhedrin 15, 10-13, lists all the transgressions for which a person could have been given the death penalty in a Sanhedrin [but even then, our sages teach that it was almost never carried out (Mishna Makot 1, 10), and mainly served as a threat or deterrent to stress the severity]. 40 lashes was for transgressing a negative Torah commandment which contains an action (e.g. eating pig, but not for forbidden speech which is not considered an "action"). There are other intricate details involved but these are the basics.