Here's how it works:
* Prefix + Base Word = New Word
* un + happy = unhappy
The prefix "un" often creates the opposite meaning of the base word.
To determine the part of speech, you need to look at the whole word that the prefix is attached to. For example:
* unhappy is an adjective.
* undo is a verb.
* untie is a verb.