Which is more important for PhD applicants — Quality or quantity of research papers? While applying to a PhD program in computer science, which one is more important?

Publishing 4 or 5 medium/low-quality journal or conference papers or publishing only one paper in a top journal?

The review process of top-quality journals are usually 1-2 years. Which means, one has to begin his/her research during the bachelor's and submit the paper in the beginning of master's degree. But as far as I know, this is extraordinary (especially in my country).

An extra question would be: Regardless of the quality of the paper, is publishing papers in distinct areas or publishing papres in a specific area more important?

I'm willing to move to Northern Europe (UH, TUT, KTH, KU). So, answers from the professors/students of those universities will be highly appreciated.
I disagree with the assumption that top journals with slow turnaround times are more highly regarded than top conferences with quicker turnaround times.  In most (all?) areas of computer science, the most competitive conferences are at least as highly regarded as the top journals.  It is also not unusual for longer versions of conference papers to later be submitted to journals.

As David Patterson (UC Berkeley), Larry Snyder (University of Washington), and Jeffrey Ullman wrote in Evaluating Computer Scientists and Engineers For Promotion and Tenure:


  The evaluation of computer science and engineering faculty for
  promotion and tenure has generally followed the dictate "publish or
  perish," where "publish" has had its standard academic meaning of
  "publish in archival journals" [Academic Careers, 94]. Relying on
  journal publications as the sole demonstration of scholarly
  achievement, especially counting such publications to determine
  whether they exceed a prescribed threshold, ignores significant
  evidence of accomplishment in computer science and engineering. For
  example, conference publication is preferred in the field, and
  computational artifacts —software, chips, etc. —are a tangible means
  of conveying ideas and insight. Obligating faculty to be evaluated by
  this traditional standard handicaps their careers, and indirectly
  harms the field. This document describes appropriate evidence of
  academic achievement in computer science and engineering.


Your research advisor should be able to provide you advice more specific to your case.

I agree with amirg that having any publications when applying to a PhD program (especially based on undergraduate research) makes you exceptional.  Your advisor's recommendation also counts a lot, especially if he or she is well known.