Dark Horse Programmer--java Basics-Installation and configuration

Source: Internet
Author: User
Tags float double

------Java Training, Android training, iOS training,. NET training, look forward to communicating with you! -------

Configure environment Variables path: Search through the path system for executable Java files. JAVA_HOME:JDK installation directory classpath: Load directory Why do I need to configure path, when need Classpath?path: System variable path tells the path of the system executable file, when an executable file is found, the default is to first look for the current directory , if it is not found, it will go to the path set path to find, and then execute. Classpath: is to tell the JVM where to use or execute the class file, and when the class file is placed on a different path, if you are using or executing the class file in the current directory, you need to set the classpath path to tell the file where it exists. JDK and JRE and Jvmjdk:java Development Kit Jre:java Runtime Jvm:java virtual machine Java program run procedure 1. Compiling Javac    : Compiling Java source files into a class bytecode file 2. Run Java: Run the class file identifier: function: Name rules for class and method variables 1. Start with a letter, underscore, $2. Cannot be a keyword 3. The remainder can be: letters, underscores, $, numeric variables: 1, local variables The definition must be initialized manually before it is used within a method or within a block of statements that belong to a method or block of statements. 2, the member variable is defined inside the class, outside the method. The system is initialized automatically if the member variable is not initialized manually. The rules for initialization are as follows: Number: 0,0.0 boolean false char \u0000 reference type: NULL3, static variable defined inside class, outside method, using static modifier, from class, class name can be used. The variable name is called directly if there is no manual initialization of the static variables, the system is initialized automatically and the initialization rules are the same as member variables. Data type: 1, basic data Type a) numeric integer: byte short int long floating point number: float double b) character Char c) Boolean boolean2, reference type (4 bytes A) array B) object C) interface type conversion: Automatic conversion, expression: 1, the type of the automatic lifting expression if there is a long, the result is a long expression if there is a double, the result is double. 2, cast operator 1, arithmetic operator 2, relational operator 3, logical operator 4, bitwise operator 5, assignment operator 6, trinocular operator (boolean expression)? A:B control Statements: 1. Sequential structure 2. Select Structure a) if b)If else c) switch multi-value selection expression: int or char or short or byte or enumeration note break problem 3. Loop structure a) while first judgment after execute B) for c) Do when Judge break: Force terminate the entire loop continue: End this cycle, continue the next cycle

Black Horse Programmer--java Basics-Installation and configuration

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.