The above rule, melifluous though it is, has a few exceptions:

I before E, even after C: species, science, sufficient

E before I, not after C: weird, foreign, feisty

Feel free to write in with more.