The basic understanding of those logical languages, today comes to mind a problem is the difference between for and while, professionally, for and while are basically the same, but for is only allowed one access, if the end can not continue to access, while the while will be more than one access. Then there is the method, in Java I think the function is the method.
Format:
Modifier returns a value type method name (parameter type argument name 1, argument type parameter Name 2 ...) {
Method body Statement;
return value;
}
read the book I think the focus is the overloaded function, in the same class, the method name is the same, the parameter list is different. Is independent of the return value. Parameter list is different: The number of parameters is different. The corresponding data type of the parameter is different. Next is the array, which is basically a bit like other languages, int[] Arr=new int[3]; about this new is about the memory allocation problem of Java, in Java is divided into five types of storage, stacks, used to store local variables , heap storage all new out; the method area; Method Area (System-dependent), register (CPU use), at present, we can not touch the back, only the first two, stack it is to store local variables, the data after the use of it disappeared. Heap new things are in the heap, every one of the new things have an address
if we define an int arr3[]=arr at this time, then ARR3 is the address of ARR, at which point the ARR3 points to the address space of arr in the heap.
Fourth day of Java learning