The next command line, the next to the six kings of black road students

Source: Internet
Author: User

The next command line, the next to the six kings of black road students

Today, I started to access the Linux command line interface again. I was very excited. It was originally the time for c ++, and all the results were used here, I haven't touched this interface for several years, and I almost forgot to turn off the command lines I learned before. Today I started to touch this thing again. The whole screen is black and white, and I feel very good, I started from the basics again.

In the graphic interface [run level = 5] in centos 7, I excitedly pressed Ctrl + Alt + F3 to enter the plain text interface [run level = 3 ], I tried it. In this version:

Ctrl + Alt + F2 ~ F6 can enter the text interface to log on to the tty1-tty5 terminal [terminal or console]

 

Ctrl + Alt + F1 enter the GUI desktop

 

 

Linux has two desktop types: GNOME desktop and KDE Desktop. I used GNOME Desktop. During this installation, I chose GNOME to install it, the figure above is part of the GNOME lock screen.

After entering, there are only three icons

 

The first icon is "Main folder", the second icon is "recycle bin", and the third icon is "network connection '.

In the lower-right corner of the desktop, '123' indicates that there is a work zone. Do you still remember that Linux is a multi-user, multi-task operating system, by default, there are four work zones after installation. I have set 4 to 1. Hey, there is nothing to say here, after entering gnome, you can start with a mouse as you have just started learning Windows, change the wallpaper, brightness of the screen, and enjoy watching music and movies, surfing the Internet and other things are simple. There is nothing to say about it, so you don't have to talk about it again.

The user name I set is shutong. I will use it to log on to the text interface. Press Ctrl + Alt + F2 to enter the text interface, which is monotonous but full of mysterious black and white characters, if I want to log on, use the shutong user,

 

The User Name shutong is displayed in the prefix, which proves that I have successfully logged on. last login shows the time when I logged on last. When you typed the password, the password: it won't happen again *, but never think that the keyboard is useless. "Login" is a program in Linux that enables users to log on.

 

After logging on successfully, let's practice some simple commands in Linux. [NOTE: When you enter a command, you must pay attention to the Case sensitivity. in Linux, uppercase and lowercase are different]

1. cal

The cal command is a tool used to view calendars. directly enter the cal command to display the calendar of the current month, which is highlighted this day;

The cal command is followed by a year to view the calendar of the year;

The cal command is followed by the year and month to view the calendar of a month;

As shown in:

 

 

2. echo $ LANG ----- view supported languages LANG = zh_CN.UTF-8 -------- change language to Chinese Language

 

3. bc command ------ a simple and easy-to-use Calculator

Enter bc and press enter to enter the Calculator

 

You can perform some simple calculations.

If you want to leave, enter quit and press enter to return to the command prompt.

[Note] If you directly enter 10/100 for the computer to solve the problem, the result will be 0, because it only outputs the integer part by default. If you want to get the real result of 10/100, scale = number is used to specify the number of digits after the decimal point in the output result. For example, scale = 3 --> indicates that the output result is the last three digits after the decimal point.

 

4. date ----- display the current exact time

Date + % y/% m/% d ----- output the date in the format of year/month/day

Date + % H: % M ----- output in time: minute format

 

 

I want to log out, exit and press Enter.

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.