C++ for Ruby scripters
I am a fairly capable Ruby scripter/programmer, but have been feeling pressure to branch out into C++. I haven't been able to find any sites along the lines of "C++ for Ruby Programmers". This site exists for Python (which is quite similar, I know). Does anyone know of a guide that can help me translate my Ruby 'though开发者_开发问答ts' into C++?
I don't think that language introductions written specifically for migrants from a certain language have considerable advantage over traditional "independent" introductory books. Reading as a cognitive process has a great feature: reading speed varies greatly. That means that you should take any good C++ book (I'm sure you'll find excellent recommendations here on SO) and your reading speed will be greatly affected by your previous programming knowledge - reading about things you already know will become almost skimming-fast, others will take some time. In the end, you will spend practically the same amount of time as you would if you read a specific migrant course, with the difference of having read a book that you will be able to use as a language reference at any given time in the future, unlike the "transitional guide", which is always kind of "one-time read".
On the other hand, from a perspective of a writer, it's pretty ungrateful to assume (and rely on) such thing as reader's knowledge on a topic. When one says he knows Ruby is it really a guarantee that he knows OOP thoroughly, for example? Or just have been using it not understanding the internals (which is really easy for a Rails programmer, for example).
So a general book is a safe bet both for a writer and a reader. :)
I agree with others. Your skills in Ruby will certainly help you to learn C++ in a way, but they are quite different. A great online book to learn C++ : Thinking in c++
Bruce Eckel's books are a really good start with an adapted learning curve. Simple to begin but going quite deep into the language. Recommended.
my2c
If you want to learn C++, start here. Once you have learned the fundamentals, you should also look into these: Effective C++, More Effective C++, Effective STL, and Exceptional C++
精彩评论