The " 'n " is used when the word that comes before it ends in a vowel. If the word before it ends in a consonant, "yn" is used instead. Thus, "dw i'n hoffi bacwn" and "dw i ddim yn hoffi bacwn".
Because the word before it ends in a consonant. In Welsh, the vowels are A, E, I, O, U, W and Y. If the word ends with any letter other then these, you should use "yn" instead of " 'n ". Thus, "Dw i'n hoffi" and "Dw i ddim yn hoffi".
Seems to be taking me hours to get through this present tense. I've finished all units apart from politics before but just let it go for a while. So frustrating !