Think of it like this:
A man makes a mistake and breaks the law. He goes to jail. A little while later he is granted parole. There are two conditions: stay out of trouble and report in once a week. If he can do this he'll be granted full release.
Man broke the law when he ate from the Tree of Knowledge. Christ died on the cross to give us parole. He gave us two conditions: faith and works. If we can do this we'll be granted eternal salvation.