If you have a strong liking for something, you have a preference for it. You might have a preference for apples, but there are some days when you're stuck eating a banana instead.
If you grant favors to one person over another, then you are showing a preference or bias. The United States often gives preference to traditional allies like Britain or Canada. In your science class, it's clear that the professor has a preference for certain students and calls on them more often. Preference also refers to a choice or the right to choose — your friend might have a strong preference for which movie you'll see tonight.