1 Attachment(s)
Is my programming good enough?
Hi
I've written a console program in C++ and I'm wondering if the standard of the code is acceptable on a professional level. Now that I've finished studying, I'd like to use the program as my 'calling card' to get commercial work. Is my programming good enough for that level?
Your feedback would be much appreciated. I've attached a text document containing the code to this message.
Panther2
Re: Is my programming good enough?
Quote:
Originally posted by panther2
Hi
I've written a console program in C++ and I'm wondering if the standard of the code is acceptable on a professional level. Now that I've finished studying, I'd like to use the program as my 'calling card' to get commercial work. Is my programming good enough for that level?
Your feedback would be much appreciated. I've attached a text document containing the code to this message.
Panther2
(1) You mix stdio and iostream
(2) You use <iostream.h> -- deprecated; use <iostream>
(3) The code is hard to read and hard to maintain
(4) The code is not well structured -- very repetitive
(5) You use "magic numbers"
(6) You don't check the user input
The same program could be written in half the lines you needed.
You asked for critique and oppinions, so here is my oppinion: the code is beginner level -- very far away from the professional level. Don't show this code in a job interview.
Sorry for being so direct, but I'm trying to be honest.
Re: Re: Is my programming good enough?
Quote:
Originally posted by Gabriel Fleseriu
(5) You use "magic numbers"
What are "magic numbers"?
:confused:
Re: Re: Re: Is my programming good enough?
Quote:
Originally posted by Doctor Luz
What are "magic numbers"?
:confused:
Magic numbers are nontrivial numbers hard coded inmiddle of the code.
Quote:
Originally posted by KevinHall:
Anyone else with ideas on what other books should Panther read?
"The C++ Programming Language", 3rd Ed., by Bjarne Stroustrup
"Exceptional C++" and "More Exceptional C++" by Herb Sutter
"Effective C++" and "More Effective C++" by Scott Meyers
I know that many people would call these books "heavy artilery" but that's what I'd go with.
Re: Entry level engineers
Quote:
Originally posted by dude_1967
panther2,
All forum users,
Don't be so hard on the guy!
The guys asks us to criticize his piece of code, I think we are giving him a fair evaluation. I think we've all been fair with our evaluation and to be honest with you, I think it is better to be harsh at first then find out the hard way we had too many illusions. If the guy can't take criticism, then programming is not his path, as we all know our designs gets criticized from time to time by newcomers with new experiences. This doesn't mean that his code didn't serve any purpose, certainly the guy learned a lot from this exercise, maybe now he just needs to build a real challenging application. That would be the next step in my opinion.
And as others pointed out, employers do not necessarely seek gurus all the time, they will want to give formation to the newbies to mold them to their philosophy of work. Being honest about your capabilities is the key to a sane work relationship. But I honestly do not think that showing this code we saw would be giving the guy any edge whatsoever and can even hinder his chances for hiring as the boss would think the guy has not come to ground with reality.
Quote:
Usually, when hiring for a permanent position, we try to build a complete picture of the candidate. This includes many aspects such as emotional stability, positive energy and a record of a consistent and sucessful performance in education. With practice and a healthy development climate, new engineers learn from the more experienced developers. Older developers benefit from the creativity and youthful energy of the new dudes.
Exactly.
Finding compatible workers (programmers) is also a challenging task and sometimes clashes can occur, that is the most important thing to be careful about in my opinion, as it can drive down productivity a great deal when people do not share the same programming philosophy.
[/QUOTE]
Good luck.
Re: an additional thought
Quote:
Originally posted by galathaea
It doesn't quite work that way in this field. You never finish studying in technological fields, because there is always new stuff to learn...
Indeed. I've seen one too many senior programmers who relied on "old" technologies (DB2, Mainframes...) realize they were now incompetent in new technologies (Internet, Desktop applications...) that they went into deep depression.
It's never a good news to learn you have become useless part of the workforce. Be careful guys. We didn't choose to program because it was easy, but because it was hard. :)