Computer languages are divided into high-level languages and low-level languages. High-level language is mainly relative to assembly language (machine language). It is a highly encapsulated programming language; it is programming that is closer to natural language and mathematical formulas. It is basically separated from the hardware system of the machine and is easier for people to understand. Write a program in a certain way; the program you write is called a source program.
High-level language is a programming language based on daily human language. It is expressed in words that are easy for ordinary people to accept (such as Chinese characters, rules (English or other foreign languages), making it easier for programmers to write and more readable, so that people with less computer knowledge can roughly understand its content. (Recommended learning: PHP programming from entry to proficiency)
High-level language does not refer to a specific language, but includes many programming languages (dozens of ), such as popular java, C language, c, C#, PHP, python, Perl, pascal, lisp, prolog, Visual Basic (referred to as VB), FoxPro, delphi, easy language, fortran, etc., the syntax and commands of these languages The formats are all different.
PHP is a high-level language and assembly is a low-level language. Generally speaking, the higher-level language is simpler, but has poorer control over the bottom layer, and the lower the efficiency; the lower-level language is more complex, has better control over the bottom layer, and has higher efficiency; the lowest level is machine code.
Machine language is a programming language or instruction code that can be directly recognized by the machine. It does not need to be translated. Each operation code has a corresponding circuit inside the computer to complete it, or it means that it can be processed without translation. It can be a programming language or instruction code that is directly understood and accepted by the machine.
Machine language uses absolute addresses and absolute opcodes. Different computers have their own machine languages, that is, instruction systems. From a usage perspective, machine language is the lowest level language.
Programming language is a formal language used to define computer programs and to issue instructions to the computer. There are many computer languages, and a large number of new programming languages are created every year.
According to levels, programming languages can be divided into three categories: machine language, assembly language and high-level language. Machine language consists of a set of machine instructions that can be directly executed by the machine.
Programs written in machine language have problems that are difficult to read and remember. Assembly language essentially operates directly on hardware. Due to the use of mnemonics, it is more convenient to write and read than machine language.
In high-level languages, multiple assembler statements are merged into more concise programming statements, and at the same time, some tasks such as stack and register allocation management are automatically completed, making it more convenient for programmers to develop programs
To write programs in machine language, programmers must first memorize all the instruction codes of the computer used and the meaning of the codes. When hand-programming, programmers have to handle the storage allocation and input and output of each instruction and data by themselves, and they also have to remember the state of the work unit used in each step of the programming process.
The above is the detailed content of Is php a high-level language?. For more information, please follow other related articles on the PHP Chinese website!