I am already 23 and I am developing javaSE from past 2 years, yet I am not very much comfortable programing in general.
Actually I am having trouble to implement algorithms or somethings like 'developing logic'.
I drew up a conclusion that I need to focus more on algorithms, but some how I am quiet weak in it.
Apart from my regular courses, I am self trained java programer by programing approximately 2hours a day.
I tried my hands on code-chef and project euler.
Solved about 40 problems now from project euler.
And many more coding problems, I developed board games, but I always used the inefficient method, and its a bad habbit that I cant get rid off.(eg, using dynamic memory allocation in AI, slows down the speed tremendously).
I neither do have formal back-ground in mathematics nor in computing, but I wish to be a good programmer, I am willing to put up my efforts, can anyone guide me how to be a better programer?
Never stop the studding also. Read books about this subject.
If you practice a lot you will know how to apply that book knowledge.
There is one very good named Clean Code.
Joined: Dec 29, 2009
@Everyone : First of all I thank you all for taking out sometime to help me.
@Stephan van Hulst: No I havent read that, but when I started programing, I used complete-reference java.
@Bear Bibeault: I agree, but until I posted this, I was confused and didnt know what to do. I was just learning to swim by jumping in well, without any life-guards or floats. Thus I wanted to get my programing on the right foot. What bothered me was the bad practices which I kept on developing.
@Hebert Coelho : this is in reference to your first post, I am trying to get into graduate CS course, but I don't want to be a programmer all my life, I want to explore new areas in field of CS.
It also depend on what job I get and what they tell me to do.
I have just browsed through the reference you gave, seems to be quiet a nice one. Thank you.
@John de Michele : I am trying my hands on it currently, I am using Introduction to Algorithms (CLRS) to study algorithms. I am finding it hard to digest, can you suggest anything else some simple book on algorithms, it will be helpful.
So now I think I have to read effective java and the clean code first, then data-structures and algorithms based on java.
Ashish Schottky wrote:...What bothered me was the bad practices which I kept on developing...
Don't sweat it (too much). I've been programming for 35 years and Java is my 8th working language; and it took me nearly 5 years before I had my "moment of clarity" with Java. My problem was that most of my previous experience was with procedural languages and I just couldn't get out of that mode of thinking. It doesn't necessarily mean that you can't write good code, just that the process will be slower.
As the others have said, find a good book (and I'll second 'Effective Java') and practise a lot.
Isn't it funny how there's always time and money enough to do it WRONG?
John de Michele
Joined: Mar 09, 2009
O'Reilly has a book titled Algorithms in a Nutshell which I found to be useful. Also, there's an older book titled Algorithms in C++ which I found to be valuable. The code examples in it are very simple, so you should have no problem adapting them to Java.