studying c++ programing ... concern

This is a discussion on studying c++ programing ... concern within the A Brief History of Cprogramming.com forums, part of the Community Boards category; hi guys! i have 1 year off school (grad school transition, hopefully ) and my company actually prefer individual with ...

1. studying c++ programing ... concern

hi guys!

i have 1 year off school (grad school transition, hopefully ) and my company actually prefer individual with c++/c# programing skill which a person, studying physics like me, doesn't have much.
So, I decided to go on my own by self-studying.

1. Reading 2 books abot C++: deitel&deitel and another one from D.S Malik "C++ program"
2. Try to do as much as exercise programs as possible.

But, i'm only at control structures (if, while, do, for, switch) and I encounter a program of separating digits from an integer number in order to add them.

I found this hard (without using string and array) and I ended up google the algorithm.

Aren't you supposed to come up with the solution by yourself?
I'm just worried about the quality of self-studying like that.

thanks for any insight!

2. I found this hard (without using string and array) and I ended up google the algorithm.
Strange, because this is a purely numeric puzzle and should be well within the realm of something a physics student should be able to do. Programming is all about problem solving. You need to break your problems apart into pieces small enough that the computer understands them.

For example, in this case your thought process should have been something like:
1) The problem is adding up the digits of a number.
2) So I need to break up the number into digits, and I need to add them together. Make that two sub-problems.
4) Now how to split a number into digits?

And yes, you're supposed to come up with the solutions to these puzzles yourself. Being able to implement an algorithm using the programming language is language basics, but not really programming.

However, I don't feel that this is really any different in self-studying and in classes. Problem solving is something that's generally expected to be picked up along the way, instead of being the focus (as it should be, IMO.)

So, what I'm saying is, continue with the self-studying. Most programmers start this way, I think. But focus on training your problem-solving skills.

3. thanks big time!
quite uneasy to get used to programming, i.e. think like a computer

4. But then again, a good programmer must also know how to use google, etc, to find solutions to their problems!