How to use enums?
<p>I'm not sure how to use enum in Java. Am I using it right in the following example?</p>

<pre><code>enum Sex {M, F};

public class person{  
    private person mom;  
    private Sex sex;

    public person(Sex sex){  
        this.sex = sex;  
        //is this how i'd set sex?  
    }  

    public void setMom(person mom){  
        if(mom.sex == 'M'){}  
        //is this how i would check to see if the sex of the passed person argument is male?  
   }  
}
</code></pre>
