Faen is derrived from the word "Fanden" directly meaning Devil or The Devil. The word is much more used as a form of expression toward self failiure, than insulting a person.
Faen is emotionaly equivelant tho the english word Fuck when used alone.
"Faen! Jeg er for sein til timen!"
"Fuck! I'm late for class!"