Thursday, November 4, 2010

light reading

I've been reading a little bit about C++. It has some neat capabilities. Classes seem a lot like structures, but they can have functions built into them and variables that can be local to the class only (private) or viewable/modifiable by anything (public). I really like the idea of housing functions inside of a class. I've ran into a few things in my meager coding attempts where I had wished I could make things more organized.

One annoyance in the C++ literature (online at least) is that there are so many names for things. See here:

http://www.learncpp.com/cpp-tutorial/84-access-functions-and-encapsulation/

I guess "access function" is a dandy name for a function in a class that will return a private variable in the class, but that's only one example that at least makes sense in context. It's just such a generic name. Constructors, destructors,encapsulation, I dunno, rambling. C has lingo, too, but it seems more sensible to me.

C++ seems to be all about keeping the bones out of sight and just letting you toss things at classes and letting them do the work. I can't imagine ever writing a program so complex that I'd need to go out of my way to do that. I totally understand now why most GUI libraries are c++ oriented.

No comments:

Post a Comment