While in class, take good, detailed notes. Strive to use tidbits that you can translate later. Don't just write down a phrase your professor uses; you may not be able to decode it later on while you are studying. Also, highlight anything the professor says more than once, especially if he or she repeats himself from one day to the next. These are, in the professor's, the most important ideas, and the things you're most likely to be tested on.
To start studying, review your notes. Just go through and read everything a few times. Don't stress over remembering details; just start off by reminding yourself of everything you've learned since the last test. Go through again, skimming over the major ideas, then go over it and over it until you know all the main points. If there are any ideas you aren't clear on, contact the professor or look it up in the textbook.
Be sure to read the textbook. Many professors intentionally test on material from the book that was not discussed in class. This is to check who has done . Also, the textbook can help to clarify concepts that you are still unclear on.
Study with someone else. There may be ideas you think you understand perfectly, but if you are wrong, a study buddy can tell you. Don't rely solely on this person, though, they won't be able to help you during the exam. Another great reason to have a study buddy is that you are nearly guaranteed to remember something if you've explained and taught it to someone else.
Finally, once you're in the exam, relax. A deep breath brings oxygen to your brain and allows you to think more clearly. You've studied hard, you know the material. Keep reminding yourself of this. Don't sit near distracting people.