1. For variables
The equal sign has the function of assignment. For example, a=3 means assigning 3 to a. This is very simple. Everyone often assigns values. In addition to judging the double equal sign, the single equal sign is assigned when initializing the object.
2. For reference objects
The equal sign has the function of passing a reference (implicit pointer). This is not difficult to understand. For example, pointer: a=b, pointer of object a Points to the address of object b. At this time, a refers to the address of b, which plays the role of passing the address.
Recommended tutorial: Getting started with java development
The above is the detailed content of What does "=" in java mean?. For more information, please follow other related articles on the PHP Chinese website!