should case fans blow air into or out of the case
Solution 1:
The point is to remove heat from the case so:
heat rises, so fans at the top of the case blow the hot air out and fans at the bottom blow cold air in.
fans near hot components (CPU, Power supply, high end graphic cards) blow air out because you want to remove the hot air - not spread it around.
you have to have good airflow where hot air is continually removed and replaced with cool air - so, fans at one side (usually the front) blow air in while fans on the other side (back) blow air out.
Solution 2:
The really important aspect of cooling is good airflow. Most cases have a front-to-back airflow: air goes in at the front and out at the back. Reasons for this direction include the location of the power supply unit at the back (a major heat generator, so its air must be evacuated directly) and the preference not to blow hot air towards the user of the computer.
The airflow is usually achieved by having an outtake fan at the back, often another outtake fan on the power supply unit, and sometimes an intake fan at the front. As mentioned before, a PSU outtake is often required, and two fans in the same direction provide more airflow than one in each direction, which explains why outtake fans are more common. Another reason to prefer outtake fans is that intake fans tend to accumulate dust (which isn't a concern if you're willing to dust the inside of your computer often).
If you're interested in the topic, I recommend reading articles at Silent PC Review, one of the few hardware sites where people measure other things than frames per second. The site is about reducing noise, but since fans are the main source of noise, they discuss airflow a lot. The very question you ask has been asked on their forum (“Case Fans - Blow In, Out or Combo?”), with no consensus answer.
Solution 3:
Well usually fans in front and at the side of the case blow air inside while fans at the top of the case and at the back blow air outside. Fans which are in expansion card format usually blow air out too.
Some people even place side fans in such way that they blow air directly in CPU cooler fan.
Also, take a look at this question.