What mistakes often make Java programmers how to learn Java programming

  Which Java programmers often make mistakes? Getting the Java industry how? Say Java language is an enduring programming language based on C ++ evolved, removing the complexity of many of the features in C ++, but this does not ensure that a Java program members will not make mistakes. So for the majority of Java programmers, they often mistake what is it? Look at it together below!

  

What mistakes often make Java programmers how to learn Java programming


  1.Duplicated Code

  Code duplication can be described as very common problem. He is also one of the main objectives Refactoring. Code duplication is often derived from the copy-and-paste programming style. He corresponds with OAOO is an important indicator of a good system.

  2. ignore abnormal

  We often ignore abnormal. However, for beginners and experienced Java programmers, it is recommended to manage them. An exception is usually thrown with a purpose, so in most cases need to record the cause of abnormal events. Do not underestimate this, if necessary, you can re-throw it, show an error message or an error message to the user logged in a dialog box will. At least, in order to allow other developers to know the cause and effect, explain why you should not handle the exception.

  3.Hashtable vs HashMap

  In the algorithm, the hash table is the name of the data structure. But in Java, the name of the data structure is HashMap. One major difference between HashMap Hashtable and are, Hashtable are synchronized. So many times, you do not need a hash table, HashMap would suffice.

  4.Divergent Change

  Rate of change of a different content class inside. Some state one hour time change, some are only changed once a year a few months; some state the reasons for this change because of the occurrence, while others change because of other reasons once. Object oriented abstraction is relatively constant and the relative change in phase separator. The changes on the one hand and on the other hand the problem is isolated. This makes them relatively constant can be reused. Changes in every aspect of the problem can be reused individually. This coexistence of different changes such that reuse is difficult.

  The above is a summary of several big mistake often made by Java programmers, Java can effectively help newcomers avoid detours, less overtime, and write more robust applications. If you have a solid technical foundation, went to get a high salary job becomes very easy. Select professional learning, we will help you faster and better to join the Java programming industry.


Guess you like

Origin blog.51cto.com/14551723/2463868