I am building a pc and i dont know to use Intel i5 3570k or AMD FX 8350?
Probably neither ;) Depends on what you are Planing to do with the PC. Strictly Gaming? Get a 760K FM2+ and a R9 280X/GT 770.
The (OC'ed to 4,6 GHz) 760K and a 270X run Crysis 3 in F-HD with Very High Settings @ 35-45 FPS, BF4 runs at Ultra with 25-30 FPS - but in that Case, the 270X is the Problem, because the CPU-Load is no where near 85%.
Extensive Video-Editing? 8350, because of the 8 "Cores".
With the given options, I would assume you are trying to build a high-end gaming system. They are equally good, you wouldn't be able to tell the difference in performance in 9/10 games.
The 8350 is a much more versatile chip which would produce a boost in productivity - in the right software suites it can beat an i7 in productivity.
Unfortunately, you're limited to the ATX form factor. I find that the other drawback to the 8350 is the very limited selection of "suitable" motherboards. The expensive AM3+ motherboards can often negate the price difference between this option and the i5 and a given Z77 or Z87 (4th generation 4670K) motherboards.
The i5 can be placed in a smaller form factor. Good if you want to build an mITX for LAN parties, or if you live between two places.
Quad cores are absolutely fine for gaming. By the time the 4 cores of the i5 cannot keep up with games, the 8350 would also be a dead chip. This isn't about core count.