" […] if you give a man a fish he is hungry again in an hour. If you teach him to catch a fish you do him a good turn."
If you want to do any sophisticated codes, you must fully understand and know the language you're working in, so instead of asking how to do, you must learn how to do.
The world wide web have a lot of knowledge out there, just research and study brother. I'm giving a tip that helped me a lot, I hope it helps you too.