What and which are somewhat similar, and as I understand it, we always use which when a noun follows the wh-word. For example: Which color is your favourite? but What is your favourite ...
Most of the time one or the other feels better, but every so often, "which" vs. "what" trips me up. So, what's the exact difference and when should you use one or the other?