Logo 
Search:

Java Answers

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds
  Question Asked By: Tracey King   on Sep 16 In Java Category.

  
Question Answered By: Katrina Edwards   on Sep 16

I'll give you some general advice, then some specific advice:

Generally--never write your entire solution set and then try to get
it running. You should first create the most basic class, get it to
compile, then add code incrementally. If you blast out 1000 lines of
code and it won't even compile, you are in big trouble. You haven't
even figured out the logical problems, which usually crop up.

Specific--you need to edit your code in an editor that has syntax
highlighting and auto-indenting. Then if you do something dumb like
forget to use a closing brace, the tool will make it obvious when the
indentation remains.

Also, whenever you create a new block, start with the opening and
closing braces before you put any code within the block, ala:

if() {

}

Then you never forget to close the block and don't get confused as to
in which level you are.

Share: 

 

This Question has 6 more answer(s). View Complete Question Thread

 
Didn't find what you were looking for? Find more on can't compile the TestBanking.java Or get search suggestion and latest updates.


Tagged: