This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes getting frustrated learning java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "getting frustrated learning java" Watch "getting frustrated learning java" New topic
Author

getting frustrated learning java

oriakhi joseph
Greenhorn

Joined: Oct 06, 2011
Posts: 12
i am a beginner in java, hoping to be a good developer like some guys out there . I have read the SCJP book by kathy and bate, when i wanted to start developing softwares , i did not know where to start. I then, picked up the java 7 documentation API, but got stuck trying to use the swing package, am getting frustrated by my inability to move on, please can any one tell me what to do personally to get on programming effectively with java, what to study or how to study cos have read the SCJP book - first reading, I NEED HELP, and i will never forget anyone who will liberate me from this state of my frustration by advise and share experiences. Thanks
Dattatraya Tembare
Greenhorn

Joined: Feb 01, 2009
Posts: 10
Hey .. take it easy.
Get into java & then start reading documentation & SCJP books.
Start with small documents... Type "Introduction to Java + PPT" on Google / or any other search engine. You will get many MS PPTs.
When you get interest in any subject then only you will go in depth of that subject.
Happy learning
Jeff Verdegan
Bartender

Joined: Jan 03, 2004
Posts: 6109
    
    6

oriakhi joseph wrote:I have read the SCJP book by kathy and bate [...] am getting frustrated by my inability to move on


For starters, you'll want to make sure you're looking at this with the right perspective: http://norvig.com/21-days.html
Matthew Brown
Bartender

Joined: Apr 06, 2010
Posts: 4343
    
    8

The SCJP book is great, but it's not designed to help you learn Java from scratch, or to develop applications in it. It's to help someone who already knows Java to learn all the little details they need to get through the SCJP exam. You need to find a book that's aimed at beginners (or web sites aimed at a similar level). For example "Head First Java" by the same authors, or "Thinking in Java" by Bruce Eckel - you can see our book reviews for more.
Anayonkar Shivalkar
Bartender

Joined: Dec 08, 2010
Posts: 1502
    
    5

oriakhi joseph wrote:got stuck trying to use the swing package

Well, as already said,
Dattatraya Tembare wrote:take it easy

Firstly, it might help if you describe what is your exact situation. How much experience (not job experience, but coding experience) do you have in programming? How much comfortable you are with any programming language, say C? How familiar you are with OO concepts? Are you uncomfortable just because there's something different with Java, or is it because Java is your first programming language?

If you read carefully, the preface of SCJP book says that this book is not to be used to learn Java from the scratch.

Btw, unless you get all building blocks in place (e.g logic constructs - loops, basic data structures, OO concepts etc.) don't go for other stuff like threading, swing, JDBC, xml parsing etc.

It is a learning process and it takes a little time(the word little is relative ). Be patient. Try to write very small programs (say a basic calculator - without GUI, or calculation of area/volume of different shapes etc.). Try to find flaws in your own code. The more flaws you find in your own code, better your logic becomes. Take a paper and pencil and start debugging programs with nested loops. This will help you in long run.

I hope this helps.


Regards,
Anayonkar Shivalkar (SCJP, SCWCD, OCMJD, OCEEJBD)
Ryan Sykes
Ranch Hand

Joined: Jan 18, 2012
Posts: 58
Also, "reading" books will only get you so far. You really need to start writing small programs by yourself. It will take a while before you will start to feel confident, especially if you are new to programming. Head First Java is a good book that introduces you to OOP, but I did find it a bit too light as far as actual code goes. Also, it doesn't really have any programming exercises, which hinders you from learning by doing. Still, it is an excellent book to get started with. I'd recommend this book: http://www.amazon.com/Introduction-Java-Programming-Comprehensive-8th/dp/0132130807

It is very well formatted, has lots of example code, and a lot of programming exercises at the end of each chapter. They provide a collection of the compiled exercise files, which can be examined by a good java Decompiler to provide solutions if you really get stuck coding one of the exercises. I've been reading through it recently and have been coding the difficult programs (marked with ** or ***) to ensure that everything I am learning "sticks". It is amazing how much you will learn when you actually have to write code independently. Reading code in a book is very easy to do, but you will very often gloss over some important details because you are passively reading the code.
Mohamed Sanaulla
Saloon Keeper

Joined: Sep 08, 2007
Posts: 3068
    
  33

Firstly get the basics right. There have been few books suggested, I would recommend Head First Java among those books.
Dont directly jump into areas like Swing/AWT. Creating GUI looks lucrative but its really not the place a beginner should start.

And as always you can browse through the threads in the forum to see if your queries have been previously asked, if not you can always post a new query.


Mohamed Sanaulla | My Blog
J. Kevin Robbins
Bartender

Joined: Dec 16, 2010
Posts: 840
    
  13

I can relate. I can't tell you many times I became very frustrated and I was sure I just wasn't smart enough to learn this stuff. I recommend starting with Java for Dummies. I know the title is condescending, but it worked for me. And don't just read the code examples. Enter them, run them, and modify them. Do all the exercises at the end of each chapter. Don't try to start out using an IDE. Use an editor like Notepad++ and compile and run the examples from the command line. Only when you are comfortable with that should you graduate to using NetBeans or Eclipse.

It's already been mentioned that you shouldn't start out building GUI apps. Stick with console apps until you get the hang of things.

Hang in there and don't give up. It's all about perseverance.


"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." -- Ted Nelson
Jeff Verdegan
Bartender

Joined: Jan 03, 2004
Posts: 6109
    
    6

Jk Robbins wrote:don't just read the code examples. Enter them, run them, and modify them.


Excellent advice no matter what resources one uses.
John McClellan
Ranch Hand

Joined: Aug 15, 2011
Posts: 35
A lot of good advice has already been mentioned. Also surround yourself with Java programmers. Even learning Java from books and stuff, there will be blinders on your eyes until you surround yourself with people who regularly program in Java. They will mention things in front of you that you didn't even know existed, talk to you about different ways of programming, guide you in using APIs, etc.
oriakhi joseph
Greenhorn

Joined: Oct 06, 2011
Posts: 12
thank you guys for your concern, i think i am ok in OOP concept (at least was an 'A' student in C++ course when i was in the university), i developed a CMS for my department using PHP as my degree project, so i think i have basic background in programming, though i accept the fact that i should take it easy, maybe am excpecting to be a java guru from myself like a breeze, but guys, i discovered the java tutorial site from sun for swing GUI with Netbeans IDE, is it ok for me to go with that? but i dont think i would know much of the code generated by the IDE.
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 38031
    
  22
I would suggest you avoid IDEs until you are more experienced. The NetBeans GUI code tends to be particularly illegible.

If you have done C++, then books like Horstmann and Cornell would be very useful. It has a couple of chapters about GUIs.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

Matthew Brown wrote:The SCJP book is great, but it's not designed to help you learn Java from scratch, or to develop applications in it.


In fact it's worse than that. Many of the examples in the SCJP book are examples of horribly bad Java code, which test your ability to understand the language. If you only used that book to learn Java, you might end up learning that you should write code just like those examples.
Anayonkar Shivalkar
Bartender

Joined: Dec 08, 2010
Posts: 1502
    
    5

oriakhi joseph wrote:was an 'A' student in C++ course when i was in the university

If this is the case, then look no further than Core Java (Volume I & II) by Horstmann & Cornell. The book is very good and often discusses the design level differences in Java and C++. In fact Core Java book itself is a good demonstration of good programming and the book contains real life example (unlike those animal-cat-dog kind of examples). But again, the book is for serious programmers, so its ok if you don't get it in first reading. Let it take some time, but it is far better to learn good programming with real life examples during first learning itself. Even after reading it, you still feel choosy about best programming practices, then go for Effective Java by Bloch.

No offense meant to anyone, but if you are serious about programming and learning Java in general (instead of just clearing certifications), then do not rely on Sierra & Bates or Head First books. Those books are either very limited in scope, or very much focused on certification. If you want to clear the certification, then yes, you should refer those books.
Pete Nelson
Ranch Hand

Joined: Aug 30, 2010
Posts: 147

Besides learning java, what do you want to do? What interests you?

Java (like C++) is huge, and covers an endless array of subjects - multimedia, database, filesystem, web applications ... do any of these have a particular interest?

The first OOP program I wrote was a file filter to convert HTML to plain text. It was a very simplistic approach, and it never worked as well as I hoped. But I learned much from the experience, because I had a task very specifically in mind when I went to start writing. I could tell when it was NOT doing what I wanted, which gave me the opportunity to learn why it failed, and what I'd need to do to make it work right.

Conversely, I've tried on a number of occasions to "create a web service" without much of an idea of what I wanted it to do. I just wanted experience writing a web service. That has NEVER worked out ... even when my web service did something, I learned next to nothing.

Find some simple task that you want to do, and try to write Java code to do it. You'll make mistakes, you'll figure out what went wrong, you'll get it to work, and you'll learn.

Write a program that catalogs all the MP3s on your computer ... Or connects to NOAA daily & gathers weather statistics ... Or serves a grocery list to the web browser. Think of something you have an interest in, and try writing code for that. Start with something simple, but start with something you know & interests you.


OCPJP
In preparing for battle I have always found that plans are useless, but planning is indispensable. -- Dwight D. Eisenhower
Shamsudeen Akanbi
Ranch Hand

Joined: Dec 24, 2010
Posts: 71
Jeff Verdegan wrote:
Jk Robbins wrote:don't just read the code examples. Enter them, run them, and modify them.


Excellent advice no matter what resources one uses.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: getting frustrated learning java
 
Similar Threads
SCJP & Books
SCJP Preparation
Aiming for SCJP
Need Advice for SCJP exam.
Isnt SCJP an overkill