You can spend months developing the expertise needed to get exactly the right kind of RAM for your Mac. But I do not recommend that.
• Buy from a Mac-savvy dealer, never from a department store or general electronics store. This rewards the companies that have chosen to provide real Mac support, not just, "I think these will fit Macs, too."
• Tell them what Mac you have, and they should provide you with the right memory, "Guaranteed to work in your Mac or your money back." That acts as an incentive for them to get it right the first time. If they are not sure, shop elsewhere. There are lots of reputable dealers who play by these rules.
• They should provide a lifetime warranty. If it ever fails, they will replace it. This is an incentive not to sell junk.
I like dealing with this company, because their prices are good, and they tell you exactly what they are sending. For me, it has always turned out to be true to its description and work first time, every time:
http://www.datamemorysystems.com/G3_Memory.asp