20165202 2017-2018-2 "Java Programming" 1th Week study summary
Summary of learning contents of textbook
- Installing the JDK in Ubuntu environment
- Simple Java Program Writing
- Anti-compiler Javap.exe
- How to install and use Git
- Learn how to use vim
problems in teaching materials learning and the solving process
Java cannot be installed in Ubuntu
Workaround:
Refer to "How to install Java 9 in Ubuntu via PPA"
Add webupd8team Java 9 PPA Library to the system and install Oracle Java 9
$ sudo add-apt-repository ppa:webupd8team/java $ sudo apt-get update $ sudo apt-get install oracle-java9-installer
Verifying the Java version
$ java -version
Code cloud hosting fails to get public key
Workaround:
Refer to Hudonghui seniors ' use git to push code to open source China and IDEA environment
During the installation, ask if you want to modify the environment variables and select the second item "Use Git from the Windows command Prompt" to run the Git command in Windows command-line cmd (which is handy)
Use the GIT installation path to find a hit git-bash.exe
, double-click to run, and enter the following commands in the command window that pops up
ssh-keygen -t rsa -C "[email protected]"
Continuous input enter, a folder named. SSH is generated under the current User folder, open the file named in the folder with Notepad id_rsa.pub
and copy all of the contents. To get the public key
Problems in code debugging and the resolution process
vi src/Hello.java
cannot be entered by editing code
Workaround: Learn how to use vim
I edit at the current cursor
I Insert at the beginning of the line
A inserts at the end of A row
A inserts an edit after the cursor
o Insert a new row after the current line
O insert a new row before the current line
CW replaces characters from the position of the cursor to the end of a word
Input from Normal mode: Enter command line mode, enter WQ carriage return, save and exit edit
git add .
Command not valid
解决方法:输入git init建立空仓库
Workaround
Reminds me to pay attention to the case and the Chinese and English input method problems, ";" and ":" The difference is very big
Code Hosting
Code Cloud Link
last week's summary of the wrong quiz
1. The following description of the characteristics of the Java language, the correct group is
C. Object-oriented; platform-independent; dynamic
20165202 2017-2018-2 "Java Programming" 1th Week study Summary