Starting programming in C++

Soarin

2[H]4U
Joined
Jul 23, 2010
Messages
2,489
Okay guys the reason I am starting in C++ is because from my friend, who programs, told me that C++ is a little confusing but learning it first makes other languages easier to learn. I did forgot to ask him before he left what tools to use. He did say learn in linux because of free compilers and what not.

My goal is to get a head start on programming I am not lost when I get into college again.
I understand C++ is more OS based apps and Java is more web based. (If I am reciting what he told me correctly)

Need to know what tools to use to start this off. Please and Thank you.

He also mentioned learning cryptography looking for some good info on that.


Oh the reason i am asking is for career wise and for myself. I have an interview at a company tomorrow that does Digital imaging and programming.
 
Last edited:
Visual Studio Express is also free.

What was the context of his recommendation? Did you have a goal in mind? Is C++ the right language for it? How will cryptography help?
 
Just get the express edition from Microsoft. Completely free and will be fine for what you will be learning for a while.

Link

I really liked this book as it was my first C++ book I learned from. Starting out with C++ Early objects by Tony Gaddis.
 
Visual Studio Express is also free.

What was the context of his recommendation? Did you have a goal in mind? Is C++ the right language for it? How will cryptography help?

Part of what I want to do is to security test and fix exploits, white-hat if you will.
Just trying to get knowledge for myself with the C++.
Cryptography is for myself, not for illegal use. That I swear by.
 
Just get the express edition from Microsoft. Completely free and will be fine for what you will be learning for a while.

Link

I really liked this book as it was my first C++ book I learned from. Starting out with C++ Early objects by Tony Gaddis.

Thanks for the link.
 
I will be completely honest I am doing this to ethical hack. Plain and simple, no bs approach, or wording to sound innocent. I want to learn what the bad guys do but utilize it for good. Yes the job I am looking at is programming, but the crypto i asked about has nothing to do with the job I do no think.
So yeah, judge me as you will but thta Is what I want to do and computer security, network testing
 
Passed college Algebra 2 with a 2.8gpa. Math is fun to me.

You'll need a lot more math than Algebra to really get a solid grasp on crypto algorithms. Start learning linear algebra (matrices) and that will get you into some initial crypto algorithms (not secure, but still technically cryptography).
 
I will be completely honest I am doing this to ethical hack. Plain and simple, no bs approach, or wording to sound innocent. I want to learn what the bad guys do but utilize it for good. Yes the job I am looking at is programming, but the crypto i asked about has nothing to do with the job I do no think.
So yeah, judge me as you will but thta Is what I want to do and computer security, network testing

You're trying to climb Everest when you're just learning to walk. Step back a bit and (oh crap, going to sound like mikeblas here) learn machine code, learn the "how" of the computer. Learn the "how" of the compiler. Learn the "why" of algorithms. Learn the "what" to look for.

I doubt you're going to be breaking crypto without spending a lot of time doing advanced mathematics. However, you may be able to find other types of exploits, if you're willing to put in the time and effort. Lots of time, lots of effort.
 
I was like you once. Then I realized programming is fantastically hard to learn and maintain the skill set. So after college I focused on SQL and have done quite well with significantly less work. DBA's and analyst make pretty much the same as programmers if not more.
 
I don't understand why so many people still learn C++. It is simply primitive when compared to the offerings of C#, Java, and especially Groovy and Ruby.

The idea that there is a hierarchy of languages, and that you must learn some before learning others is simply not correct. If you're going to get into programming, you'll be picking up a new language every 2-3 years anyway.

I'd say if you're going to work on windows Desktop software go for C#. If you're thinking about web applications and web security, then Java or Ruby are better. Even PHP if you feel so inclined. Oh the pure simplicity of PHP!
 
I don't understand why so many people still learn C++. It is simply primitive when compared to the offerings of C#, Java, and especially Groovy and Ruby.

The idea that there is a hierarchy of languages, and that you must learn some before learning others is simply not correct. If you're going to get into programming, you'll be picking up a new language every 2-3 years anyway.

I'd say if you're going to work on windows Desktop software go for C#. If you're thinking about web applications and web security, then Java or Ruby are better. Even PHP if you feel so inclined. Oh the pure simplicity of PHP!
We're on Step 5 already!
 
I was like you once. Then I realized programming is fantastically hard to learn and maintain the skill set. So after college I focused on SQL and have done quite well with significantly less work. DBA's and analyst make pretty much the same as programmers if not more.
Nah, you're thinking of a code monkey. Programming is about creating/ inventing solutions to solve challenging problems, think quality rather than quantity. You couldn't pay me enough to switch to a DBA or analyst.

We're on Step 5 already!
There you go, now were on step 6 :p
 
Well if this is a common enough question someone should put a sticky up or a cut and paste response.


since your going to be going to school for programming it is probably better to not learn anything until then as having 5 minutes with a good professor is better than having an hour tying to teach yourself.

When I first started programming the most difficult task was remembering syntax. I knew what I wanted to do but always had to look up the correct syntax to get it done. So any book with the basic Hello world type crap should help you familiarize yourself with syntax.

Once you have syntax down then next important thing is to practice the more code you can write using your brain and not having to look it up the better.

After you can write small programs from your mind find a friend. Think of a program you'd like to write. Draw up the class diagrams together and then split the programming in half. You program your classes he programs his then you merge them into the final product. Once you can do this then your ready for an entry level programming job.

My first class used VB6, then Java then C# then other none OOP like PHP, jsp, and asp. So what you start it doesn't really matter as long as your learning the core concepts.



Also programming wasn't/isn't fun for me and most others. Someone who likes to program is a rare bread.
 
I don't like to program, I like to solve problems, generally using code. There's a significant difference, though many would say they're one and the same.
 
Well if this is a common enough question someone should put a sticky up or a cut and paste response.


since your going to be going to school for programming it is probably better to not learn anything until then as having 5 minutes with a good professor is better than having an hour tying to teach yourself.

When I first started programming the most difficult task was remembering syntax. I knew what I wanted to do but always had to look up the correct syntax to get it done. So any book with the basic Hello world type crap should help you familiarize yourself with syntax.

Once you have syntax down then next important thing is to practice the more code you can write using your brain and not having to look it up the better.

After you can write small programs from your mind find a friend. Think of a program you'd like to write. Draw up the class diagrams together and then split the programming in half. You program your classes he programs his then you merge them into the final product. Once you can do this then your ready for an entry level programming job.

My first class used VB6, then Java then C# then other none OOP like PHP, jsp, and asp. So what you start it doesn't really matter as long as your learning the core concepts.



Also programming wasn't/isn't fun for me and most others. Someone who likes to program is a rare bread.

I disagree with every point you made and every opinion you expressed.

Syntax is really never -- even when starting out -- the hardest part of programming. If it is, you're doing it wrong. You're either not learning computer architecture concepts, not writing code that's challenging enough, or you're using brainfuck.

You shouldn't be looking up any code. You might look up an algorithm, but if you're just copying and pasting, you're not adding any value to whatever it is you're doing.

Your assertions are all based on your personal experience without any establishment of your own success and the presumption that you did it, so it must be the right way. That's a terrible way to give advice, really.
 
Last edited:
I don't like to program, I like to solve problems, generally using code. There's a significant difference, though many would say they're one and the same.
This is a very good point. Very insightful, although I suspect non-coders will fail to fully grasp it's significance.

I enjoy having the versatility to solve whatever problem is presented, and that means I must use whatever language is most appropriate. Over this past week alone, I have worked in bash, vbscript, sql, php, javascript. Last week it was java, the week before that c# and c/c++. Not because I enjoy coding, but because I like solving problems.

Each language has it's use, although I'll admit it's a bit jarring going from things like vbscript to bash.
 
I don't like to program, I like to solve problems, generally using code. There's a significant difference, though many would say they're one and the same.

Solving problems is boring. I like coming up with new pointless syntax structures

such as

myvar = value1 || value2 || null

In some languages it will return the boolean value(always true if null is a nullclass), but in others it will return a value or null.
 
I disagree with every point you made and every opinion you expressed.

Syntax is really never -- even when starting out -- the hardest part of programming. If it is, you're doing it wrong. You're either not learning computer architecture concepts, not writing code that's challenging enough, or you're using brainfuck.

You shouldn't be looking up any code. You might look up an algorithm, but if you're just copying and pasting, you're not adding any value to whatever it is you're doing.

Your assertions are all based on your personal experience without any establishment of your own success and the presumption that you did it, so it must be the right way. That's a terrible way to give advice, really.

You are correct he should just follow the advice you provided.

So you disagree with>

1. Learning programming from a professor is better than teaching programming to yourself.
2. Familiarizing yourself with the language so you don't have to google the correct way to write code.
3. Practice
4. learning how program code in a team

Could you elaborate on why you disagree with these because I am quite curious.
 
Programming is an art form, either you have it or you don't. if you have it, you don't need a professor.

If you don't, you can still create code, but much of the problems companies experience today is caused by people that write code without a real comprehension or grasp of how everything fits and should work.

And I use google all the time. Why memorize all the quirks of javascript and html and so forth when you can find and convert working examples?

Knowing the *capabilities* are important, the specifics are not.

As another example, java is being used as an enterprise service bus platform, it has endless numbers of procedures available. You can attempt to learn them all, or just learn the capabilities and look up the specifics as required.
 
Programming is an art form, either you have it or you don't. if you have it, you don't need a professor.

If you don't, you can still create code, but much of the problems companies experience today is caused by people that write code without a real comprehension or grasp of how everything fits and should work.

And I use google all the time. Why memorize all the quirks of javascript and html and so forth when you can find and convert working examples?

Knowing the *capabilities* are important, the specifics are not.

As another example, java is being used as an enterprise service bus platform, it has endless numbers of procedures available. You can attempt to learn them all, or just learn the capabilities and look up the specifics as required.

I'm not talking about Javascript and HTML but rather real programming, do you use google to search how to write a loop in your primary language say C++?

And since its an art form and you either have it or you don't why give advice at all because if the person was meant to be a programmer he'd already know how to program right.

Know the capabilities are very important indeed....but not for someone going into their first programming class.

A professor is in fact not needed.....But if you have one its best to use it as appose to not.
 
I don't understand why so many people still learn C++. It is simply primitive when compared to the offerings of C#, Java, and especially Groovy and Ruby.
That is exactly what a lot of people like about C++: it's primitive. It doesn't obfuscate everything it does behind a wall you can't punch your way through. This isn't a bad thing depending on what it is you're doing with it.

If you're going to get into programming, you'll be picking up a new language every 2-3 years anyway.
Depends entirely on what sort of projects you're working on. There are scenarios when there is no compelling reason to "pick up a new language" every two years, other than for reasons of boredom and general interest.
 
You are correct he should just follow the advice you provided.

So you disagree with>

1. Learning programming from a professor is better than teaching programming to yourself.
This is a different assertion than the one you made. A source of knowledge depends on the individual involved. It also depends on the other individual--the professor. There's plenty of posts in this forum where students insist they can't learn from their professors and need to get help from some other source. You said that five minutes with a professor is better than an hour with a book, and I disagree with that, as well. It depends on the individual and the book.

2. Familiarizing yourself with the language so you don't have to google the correct way to write code.
Your original post doesn't mention "Google"; maybe that's what you thought you meant when you wrote "look up syntax". Writing code is a combination of syntax and semantics. If you don't know almost all the syntax, you can't claim to be the language; if you don't know almost all the syntax of at least one language, you can't claim to be a programmer. "The correct way to write code" is really more about the semantics than the syntax. Correct syntax is taken for granted.

Better engineers won't Google for neither syntax nor semantics. Those that do aren't adding any value. They'll never be any better than the code they happened to find. They copy-and-paste security problems, inefficiencies, irrelevant comments, bugs, and all. They aren't smart enough to integrate the code properly, and will make the sum far worse than its parts.

3. Practice
How can I possibly agree or disagree with a single word? You've asked me to elaborate, but you can't be bothered to ask a complete question.

4. learning how program code in a team
Arbitrarily splitting some project with a friend and integrating the work isn't anything about "how program code in a team".
 
So you disagree with>


This is a different assertion than the one you made. A source of knowledge depends on the individual involved. It also depends on the other individual--the professor. There's plenty of posts in this forum where students insist they can't learn from their professors and need to get help from some other source. You said that five minutes with a professor is better than an hour with a book, and I disagree with that, as well. It depends on the individual and the book.

Your original post doesn't mention "Google"; maybe that's what you thought you meant when you wrote "look up syntax". Writing code is a combination of syntax and semantics. If you don't know almost all the syntax, you can't claim to be the language; if you don't know almost all the syntax of at least one language, you can't claim to be a programmer. "The correct way to write code" is really more about the semantics than the syntax. Correct syntax is taken for granted.

Better engineers won't Google for neither syntax nor semantics. Those that do aren't adding any value. They'll never be any better than the code they happened to find. They copy-and-paste security problems, inefficiencies, irrelevant comments, bugs, and all. They aren't smart enough to integrate the code properly, and will make the sum far worse than its parts.


How can I possibly agree or disagree with a single word? You've asked me to elaborate, but you can't be bothered to ask a complete question.

Arbitrarily splitting some project with a friend and integrating the work isn't anything about "how program code in a team".

I shortened the idea's because you obviously have an issue with semantics.

5 minutes with A is better than an hour with B is a rather common saying those time frames are always taken literally. The general idea is that time with A is better than time with B. Assuming the quality of his future professor.

Look up = google.

He's a new programmer he doesn't know syntax or semantics. Starting out familiarizing syntax with help him grasp and test the semantics.

Not relying on google is the objective to quote myself "the more code you can write using your brain and not having to look it up the better." And again 'look it up' can mean google. You are correct better engineers don't use google....but he's not a better engineer he's going into his first college programming class.

you said you disagree with every point I made. One of those points was to practice. Thus you disagree with practice. In a list of things you disagree with "practice" is one of them.

Programming with another person is in fact a team.
 
Yep, "practice" is bad. If I buy some golf clubs and go to the range, I can practice all I want, and I won't learn to golf. To learn to golf, I need to learn to golf. That means learning what to practice. I need to learn what I'm doing wrong, how to diagnose myself when I do it wrong, and how to correct it.

Someone who is practicing for the sake of practice is likely repeating the same mistakes. And in doing so, they're probably ingraining bad habits or knowledge. Practice doesn't make perfect. Perfect practice makes perfect.

"Look up" could mean research. Some people -- lots of the smart ones, in fact -- do that outside of a general-purpose commercial search engine.

In practice, a team is a multitude of people; it's not a single person who's already your friend. More generally, only a fool would assert that completing an arbitrary exercise (with no clear exit criteria in the first place) qualifies someone to do anything in particular. But, hey: throw your friend a football and when he catches it, call the New York Giants and tell them you're qualified.
 
Late response, just got back to where internet is available. Did not get the job, they wanted someone fluent in C# even though the ad said will train.(also mentioned in the ad that they wanted C++)
The onset of me wanting to program was not because of the job, I was wanting to learn programming for a while but when I went to enroll in classes they were all full and started already.

Thanks for the info guys. I talked to my friend and we are going to setup times and do different study together. His brother, himself and I are all in firefighter class together, and all are going for HAM license, so we will be doing programming maybe at the same time. Might just start with security+ now and wait until college to program like some mentioned.
 
You'll find that allot, that they want experience. But once you have some you can more less pick and choose (its a good sector to be in right now).

If I was you I'd buy a book before college, something like 'Learn C# in 24hours'. Read it/ work through the exercises and that will put you ahead of your peers (for the 1st year at least).

He warned though, this is not something you pick up over a weekend or from a single book, more like years (and the technology is constantly evolving). I stated college in 1999 and still not a week goes by where I don't learn something new.
 
Yep, "practice" is bad. If I buy some golf clubs and go to the range, I can practice all I want, and I won't learn to golf. To learn to golf, I need to learn to golf. That means learning what to practice. I need to learn what I'm doing wrong, how to diagnose myself when I do it wrong, and how to correct it.

Someone who is practicing for the sake of practice is likely repeating the same mistakes. And in doing so, they're probably ingraining bad habits or knowledge. Practice doesn't make perfect. Perfect practice makes perfect.

"Look up" could mean research. Some people -- lots of the smart ones, in fact -- do that outside of a general-purpose commercial search engine.

In practice, a team is a multitude of people; it's not a single person who's already your friend. More generally, only a fool would assert that completing an arbitrary exercise (with no clear exit criteria in the first place) qualifies someone to do anything in particular. But, hey: throw your friend a football and when he catches it, call the New York Giants and tell them you're qualified.

Your obviously just argumentative. No shit practicing bad practice isn't good hence why I said 5 minutes with a professor is better than an hour with a book as the main point of a programming professor is to teach the correct way to program.

Look up could also mean google and more frequently does.

2 people can be a team. Throwing a football to your friend will help you get to the NFL more than throwing a football to yourself.

But you'll find a way to argue pretty much anything I mean you are literally arguing whether or not 2 people is a team when you could just look up the definition of team.
 
Back
Top