Guitar pitch detection I try to develop a guitar game in android platform.

And I need to do the real-time pitch detection of guitar chord.

I will get the input from the microphone, and then analyze the input (the input playing which kind of guitar string/chord).

I find two kinds of method that I can use, one is YIN, another one is FFT.

Which method can get better performance and exact result?
Your question is ambiguous.  Chord, pitch and frequency detection/estimation are very different things.  Bare FFT magnitudes are really bad at guitar pitch modeling.  YIN is a better monophonic pitch estimator.  Polyphonic chord estimation is vastly more difficult, and may or may not even be possible, depending on your input data or time/pitch accuracy requirements (exactly what is your "exact result"?) plus any computational limitations ("real time" latency requirements, CPU performance/cores/GPUs available, etc.)