Unfortunately, there's no easy way to get someone else's code for Stat Attack 2. Every code is unique to the card it came on, so no one can simply hand over theirs; if they did, it would be useless to you anyway, since the codes don't work across different cards.
Your best bet is to use your own code, or to obtain a new one through the proper channels rather than relying on someone else's.