aspose file tools*
The moose likes Beginning Java and the fly likes easy or hard? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "easy or hard?" Watch "easy or hard?" New topic
Author

easy or hard?

Andreas Slirig
Greenhorn

Joined: Feb 16, 2013
Posts: 7
Hello, i have a question.

I have studied java for 4 month top now and i am having this work book, but i think the assigns you get for each chapters i really hard!

Here i have done 1 assignment




So here is my question. is it simple code for you guys that have studied java?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42280
    
  64
Is what simple? You posted some code, I don't see a question in there.

Dealing with source code that contains non-ASCII characters may not be hard, but it is certainly not common for at least 99% of developers out there.


Ping & DNS - my free Android networking tools app
Andreas Slirig
Greenhorn

Joined: Feb 16, 2013
Posts: 7
This type of code ^^, because i find it really hard do know what everything does. When i am doing an assignment i most always look back on each chapter all the time for every new thing i do ..

is it hard to train so you remember it all? because i am kind of an perfectionist when it is something that really interest me.

Is there any program out there that have all things remembered ? because i think withe the java api its hard to understand what they mean sometimes.

I am coding in TextPad, is there any program that i should use that is better for me when i am learning ?
Mack Wilmot
Ranch Hand

Joined: Jul 27, 2011
Posts: 88

Andreas Slirig wrote:

Is there any program out there that have all things remembered ? because i think withe the java api its hard to understand what they mean sometimes.

I am coding in TextPad, is there any program that i should use that is better for me when i am learning ?


Use an IDE like NetBeans IDE here: http://netbeans.org/

It will help you out some.
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 39409
    
  28
I am not convinced that IDEs help people when they are first learning.
Winston Gutkowski
Bartender

Joined: Mar 17, 2011
Posts: 8008
    
  22

Andreas Slirig wrote:This type of code ^^, because i find it really hard do know what everything does. When i am doing an assignment i most always look back on each chapter all the time for every new thing i do ..

Well, you are kind of shooting yourself in the foot by:
1. Not documenting your work properly.
2. Not using good, descriptive names. Why, for example, are your Morse code strings called 'tab'? The only thing I get when I Google 'Morse code tab' is a bunch of music references.
3. Trying to be too "clever" when you're writing code, or trying to cram too much into each method.

For example, how about this, culled from your own toLetter() method:and with a switch statement (which, since version 7, now take Strings), it would probably be even easier to follow.

Obviously, if you wanted to add tons of accented characters, you'd probably need to find another way, but it's still going to have to be a different search from the one you use for plain letters, since there won't be any direct correlation from the index to the character.

HIH

Winston

Isn't it funny how there's always time and money enough to do it WRONG?
Articles by Winston can be found here
J. Kevin Robbins
Bartender

Joined: Dec 16, 2010
Posts: 1001
    
  13

Andreas Slirig wrote:
is it hard to train so you remember it all? because i am kind of an perfectionist when it is something that really interest me.

Yes, this stuff is hard. I spent at least six months locked in a room with a computer and a huge stack of Java books. I can't tell you how many times I told my wife "I'm just not smart enough to learn this stuff." But I did, through sheer determination. It takes a lot of patience and perseverance. Hang in there. And remember that you'll never remember it all. No one does. The important thing is to remember where to go and find the information you need. You'll remember the stuff that you use frequently, but the less common stuff you'll end up going back to the documentation when you need it.

Andreas Slirig wrote:
Is there any program out there that have all things remembered ? because i think withe the java api its hard to understand what they mean sometimes.

My complaint about the api docs has always been the complete lack of examples. This site is helpful because it provides some examples by Java class, and here is a page that explains how to read the api docs. I once found a site that took the all the official javadocs and added examples to them, but unfortunately I didn't bookmark and can't locate it now. If anyone knows that site, please post the link. It was very helpful.

Andreas Slirig wrote:I am coding in TextPad, is there any program that i should use that is better for me when i am learning ?

No, that's the ideal way to learn. Don't make the leap to an IDE until you have a better understanding of what you are doing, otherwise you'll become dependent on the IDE for things like autofill and compiling. When you are ready, I concur that NetBeans is the way to go. Save Eclipse for later.


"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
Mack Wilmot
Ranch Hand

Joined: Jul 27, 2011
Posts: 88

Campbell Ritchie wrote:I am not convinced that IDEs help people when they are first learning.


NetBeans allows me to easily bring up the JavaDoc for an API class or member. It allows me to easily see members available if I don't know exactly what the name is or if something is available in the class. It is easier for me than flipping through a book or searching the Javadocs online.


Winston Gutkowski
Bartender

Joined: Mar 17, 2011
Posts: 8008
    
  22

Mack Wilmot wrote:NetBeans allows me to easily bring up the JavaDoc for an API class or member. It allows me to easily see members available if I don't know exactly what the name is or if something is available in the class. It is easier for me than flipping through a book or searching the Javadocs online.

And it also allows you to build and compile and jar without knowing the commands or even how the classpath works, which is exactly why it's not the best way to learn. Personally, I always have a copy of the API docs open in my browser, even after 12 years and even when I'm working in Eclipse.

Winston
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: easy or hard?