当前位置:网站首页>day 1 - day 4
day 1 - day 4
2022-07-27 21:41:00 【Xiao Tang learns to catch babies】
List of articles
Preface
I learned it intermittently for four months java Basics , Now I have almost forgotten , I want to spend another half month or so reviewing and sorting , This time, I only take notes of the key parts , Here is 1-4 Days of
One 、day 1 : JAVA Overview is environment related
1、java Commonly used DOS Commands and shortcuts
Refer to the previous article :IDEA Common shortcut keys and setting methods
2、 install JDK And environment configuration
1、JDK、JRE、JVM The relationship between
JDK:JAVA Development kit
JRE:JAVA Running environment
JVM:java virtual machine
JDK = JRE+ java Development tools
JRE = JVM + java Core class library of ( class )
2、JAVA Loading and execution process
1、 To write java Source code
2、javac compile , Get the corresponding .class Bytecode file
3、java function , Compile well class File loading to jvm Run in
3、 Why configure environment variables ? How to configure ?
1、java In development , There needs to be one java Running environment (JDK), Otherwise it won't work
2、 We put JDK Usually download to a directory (xx disc xx file ). For example, you are in DOS Command , Unless you are installing JDK Of bin\ Execute under directory , otherwise java Orders cannot be executed .
Why? ?
1、 If the program we are currently executing ( Or order ) Does not exist under the current directory ( No, , Can't find ),win10 The system will have an existing system named path Found in the directory specified by the environment variable of .
2、 If not found , There will be “javac perhaps java Not an internal or external command , Nor are they runnable programs or batch files ” A hint of .
3、 therefore , If we get into JDK The installation path \bin Under the table of contents , perform java or javac,
You will see javac Parameter prompt information ( That means it can be implemented java The command )
4、 And we configure environment variables in path Add the directory we need to the environment variable of ( That is to say java Operating environment )
So we can not only install JDK Of bin\ In the directory , It can be implemented in the whole system .( Any directory can execute )
5、 Because it will point to JAVA_HOME\bin, That is to say jdk Under the bin\ Catalog )
Therefore, add JAVA_HOME Variable and its value is JDK The path of .
Configuring environment variables takes only two steps :
① Increase in system variables JAVA_HOME, The path is where you are 
② In environment variable path Editor in chief ( add to )%JAVA_HOME%\bin This path 
That is to say, we can make the system stay ( That's what it says Existing ) path Specified directory of environment variables (bin\) Look under ( because bin\ The following are executable java file )
6、 We just configured the environment variables so that the system can find what we need to perform java or javac Instructions ( Because we added JAVA_HOME The variable of , And its path is JDK Where it is ( route ).)
7、 hinder path Added to the variable %JAVA_HOME%\bin And in the JDK Under the directory foundation of that layer, go further jdk Under the bin\ Catalog
Since then , The system is in path The directory specified by the environment variable can be found ,
8、 Because we have added JAVA The catalog of ,
So in the future, we need to implement JAVA perhaps javac The command can run normally ~)
ps1: Why not path Write in bin\ What about the catalogue ?
If jdk The path of changes just need to be modified JAVA_HOME One place can , Don't change it all .
Later, if you need to install more jdk Version only needs to be modified in one place .
Put a link : Why configure environment variables ? How to configure ?
Two 、day 2 : Variable 、 Data types and operations 、 identifier
1、 Variable
1、 Three elements of variable : type + name + The number
2、 Variables need to be applied before use
3、 Variables are scoped ( Cannot duplicate names in a scope )
4、 A variable represents a storage area in memory
2、 data type
1、 Eight basic data types : integer (byte、short、int 、long)、 floating-point (float、double)、 Character (char)、 Boolean type (boolean)
2、 Reference data type
class 、 Interface 、 Array
3、 Coercive transformation
3、 Operators and identifiers
Including arithmetic operators 、 Relational operator 、 Logical operators 、 Assignment operator 、 Ternary operator
Previous notes :
Variable 、 data type
Operators and identifiers
3、 ... and 、day 3 : Hexadecimal conversion 、 Three code operation 、 Bitwise operators and nested structures
1、 Hexadecimal conversion
Hexadecimal conversion
2、 Three code operation
3、 An operator
Original code 、 Complement code 、 Inverse code 、 An operation
4、 Nested structure
switch Nested structure
while And for loop
Four 、day 4 : Array 、 Sort
1、 Knowledge review :
Use of arrays and precautions
Expansion and reduction of arrays
Basic usage of two-dimensional array
Bubble sort
2、 Selection sort :
The difference between selective sorting and bubble sorting :
The selection sort is number i The elements are followed by i + 1 、i + 2… Until the last element , The first round determines the first element , The second round determines the second element , And so on ;( The number of rounds is the number of elements, and the position of the ratio remains unchanged , Just compare with the following one in turn , Then exchange positions according to conditions )
And bubble sort It's No i Elements Follow i + 1 Than , If the conditions are met, exchange to i + 1 The location of , then i + 1 Follow i+2 Than And so on **
边栏推荐
- Samsung's most advanced EUV production line has been put into operation: the 7Nm capacity this year will be three times that of last year
- CocoaPods 重装
- 怎么还有人问 MySQL 是如何归档数据的呢?
- How to realize a good knowledge management system?
- Ziguang zhanrui: dozens of 5g terminals based on chunteng 510 will be commercially available in 2020
- Worthington plasma amine oxidase (PAO) instructions
- Mobilevit learning notes
- Small change project (two versions) with detailed ideas
- Troubleshooting and resolution of program operation problems: an instance of 'std:: Logic_ error‘what(): basic_ string::_ M_ construct null not valid
- Software testing interview question: when does the software testing project start? Why?
猜你喜欢

Why use MQ message oriented middleware? These questions must be solved

Some operations about Anaconda (installing software and quickly opening)

深入理解递归的方法调用(含实例迷宫问题、汉诺塔、猴子吃桃、斐波拉契、阶乘))

微软商店无法下载应用,VS2019无法下载插件问题解决方案

@Detailed introduction of requestparam annotation

Openai issued a document to introduce the latest application of Dall · E 2: fully enter the field of artistic creation and design

CBAM学习笔记

PostgreSQL source code (65) analysis of the working principle of globalvis, a new snapshot system
![Tencent cloud [hiflow] | automation --------- hiflow: still copying and pasting?](/img/dd/8ee989f5c9db632f78e79425497e71.png)
Tencent cloud [hiflow] | automation --------- hiflow: still copying and pasting?

Analysis of STL source code
随机推荐
Search, insert and delete of hash table
An article takes you into the world of pycharm - stop asking me about pycharm installation and environment configuration!!!
UNITY--读取Excel
Common shortcut keys and setting methods of idea
CBAM learning notes
Ziguang zhanrui: dozens of 5g terminals based on chunteng 510 will be commercially available in 2020
软件测试面试题:假设有一个文本框要求输入10个字符的邮政编码,对于该文本框应该怎样划分等价类?
Worthington phospholipase A2 study phosphatidylcholine 2-acetylhydrolase
2019q4 memory manufacturers' revenue ranking: Samsung fell 5%, only SK Hynix and micron maintained growth
Comprehensively design an oppe home page -- the style of the search and oper part of the page
Software testing interview question: what is the focus of unit testing, integration testing, and system testing?
最高7.5Gbps!全球首款5nm 5G基带骁龙X60发布:支持聚合全部主要频段!
In addition to "adding machines", in fact, your micro service can be optimized like this
单核CPU, 1G内存,也能做JVM调优吗?
Software testing interview question: what project documents need to be referred to in designing the system test plan?
微软商店无法下载应用,VS2019无法下载插件问题解决方案
30 minutes to thoroughly understand the synchronized lock upgrade process
递归/回溯刷题(上)
V2.X 同步异常,无法云端同步的帖子一大堆,同步又卡又慢
Technical practice behind bloom model: how to refine 176billion parameter model?