The content in this article comes from the j2se video of Jack Ma. The data foundation in Java is a computer language, which is similar to other programming languages. We know that if we call out the benefits, learning is easy.
(1) General diagram:
On the right side, the large to small inclusion relationship is: it will be clear at a glance.
(2) Details
The two pictures are one picture. If the previous picture is macro, the next picture is the details.
Identifiers, keywords, data types, expressions, element characters, statements, and methods are personally considered to be no different from other languages such as C.
New things learned here:
1. Pay attention to the location where the local variables and member variables are declared, and declare the referenced data type variables in the data type. I may not have much understanding about this in my previous studies, it is clear now.
2. What are the differences between character and string types? The difference is: the former uses single quotes, and the usage is used as a variable; the latter uses double quotes. The usage is used as a pointer and points to the first character.
3. recursion: As mentioned in the introduction to data structures, it is actually very simple. In a word, this method calls itself. For example:
public class Test{public static void main(String[] arg){System.out.println(method(<span style="font-family:KaiTi_GB2312;">4</span>));}public static int method(int n){if(n == 1)return 1;elsereturn n * method(n-1);}}
How can we understand this self-call?
It's clear!
(3) summary:
Remember: The format is more important than the algorithm!
J2se (1)-data basics