Hear friend ,
I am not thiking that you are not good in programming becaz you know that you are don't know something aboout programming .So i am telling an advice that plz do a small program first and extend that by adding more and more code . If you get the error the check which line you added and what error msg you r getting . solve the error and proced . Dear Program can't "mugup" So Do yourself . don't copy from any where ! ok
It is good to read but what's the use when you can not implement what you have read or learnt
Try out the code on your own.The compiler is the best teacher one can ever have for programming.
Later on you can refer the docs to have an idea about the various APIs