JAVA basics: Java learning-process-Linux general technology-Linux programming and kernel information. For details, see the following. Each person's learning method is different. One person's learning method is not necessarily suitable for another person. I can only talk about my learning method. Because I learned Java completely by myself and never asked anyone, the learning process was basically entirely self-developed. I don't know whether this method is a good one. I can only provide you with some reference.
The first step to learning Java is to install JDK and write a Hello World. In fact, JDK learning is not that simple. There are two problems with JDK that are easily plagued by Java programmers: one is the CLASSPATH problem. In principle, it is necessary to understand how the JRE ClassLoader loads the Class. The other is the package and import problems, how to find the path of the class. By clarifying these two problems, we have removed the biggest obstacle to learning Java and using JDK. We recommend that you take a look at Wang Sen's "Java deep Adventure" and discuss these two issues in depth.
The second step is to learn the Java syntax. Java syntax is Class C ++. Basically, the mainstream programming languages are not class C, but similar to C ++. There is no new things, so the syntax is learned, about half a day is enough. The only thing to note is that there are several keywords that are not easy to understand: public, protected, private, static, when to use, why to use, and how to use, it may take a long time for someone to give me some advice. But later I saw Thinking in Java, which mentioned these concepts.
The third step is to learn the features of Java's object-oriented programming language. For example, inheritance, constructor, abstract class, interface, method polymorphism, overload, overwrite, and Java exception handling mechanism. For a person without an object-oriented language background, I think this process takes a long time, because I have no C ++ experience before learning Java, and I only have to figure out and modify it, I tried to read those chapters over and over again. I had to read them five times before I fully understood them. However, I think if C ++ has been verified, it should be enough time in a day or two. In this process, you can take a look at Thinking in Java, which provides a thorough explanation of object-oriented. Unfortunately, when I was studying,
I didn't see this book, so I spent a lot of time learning it through my own attempts and guesses.
Step 4: Get familiar with Java class libraries. The Java base library is the jre \ lib \ rt. jar package under the JDK installation directory. Learning the basic library is to learn rt. jar. There are many classes in the basic class library. It is said that there are more than 3000, and I have not made any statistics. But for us, there are only four at the core:
CODE: java. lang .*;
Java. io .*;
Java. util .*;
Java. SQL .*; |