practice problems

Mar 6, 2011 at 12:13pm
Hi every one. I have been learning c++ on my own and I think am doing well. But my problem has been that I have not been having a lot of exercises to practice. I would be grateful to anyone who can help me in this regard. Also I need some help with pointers. I find it confusing many times.
Mar 7, 2011 at 8:41am
Well, check out Stroustrups' book on C++. Tons of little exercises in there. Sutter's "Exceptional C++" and "More Exceptional C++" will also be a viable source for programming riddles to solve.

What exactly is it that you find confusing about pointers? I guess most beginners feel that way. :)
Mar 7, 2011 at 9:17am
I guess most beginners feel that way.


It cause enough distress to beginners that the Java creators "removed" it totally from the Java programming language.

Now to me I am neutral on this issue but I can understand the agony and anguish by beginning programmers on this tricky feature. It wields great power but also cause great destruction if not mastered properly.
Mar 7, 2011 at 9:49am
+1

[..] if not mastered properly.


But to be fair, it's also part of mastering them to know when NOT to use them. ;)
Mar 7, 2011 at 1:10pm
I think pointers are perfectly accessible. They have technological disadvantages - they make run-time safety and gc difficult. But conceptually, pointers are the iterator pattern for arrays. Single objects are the same as one element arrays. Nothing else. At least nothing portable. It is teaching pointers primarily as gateway to low level techniques with memory layout that leads to confusion. I do not advise anyone to use pointers at the first opportunity. but they are high-level sophisticated concept, and are rarely described as such.
Topic archived. No new replies allowed.