Unless you have restrictions, its much simpler to just use a set as DavidFongs suggests above. See his link, as well as How to Use Sets