List of programming languages. Low and high level programming languages

A programming language is a formal language designed to connect a person with a computer. Information and data processing algorithm are specified in the programming language. An electronic computer (computer) directly perceives a program presented in machine language, programming in which is very inconvenient for a person.

The development of computer technology has led to the emergence of programming languages. The purpose of such a language is to equip a set of computational formulas with additional information that turns this set into an algorithm. In the future, a programming language is understood as a language for compiling programs, i.e. the language in which an algorithm is written for solving a problem on a computer.

Programming for computers of the first generation was carried out exclusively in machine language. Machine language is a set of rules for encoding numerically certain actions (mostly arithmetic). For all machines, only the binary number system is understandable, which, however, was replaced by octal by programmers to shorten the notation.

The number system is usually understood as a set of methods for naming and designating numbers. The usual system of notation of numbers is a positional decimal number system in accordance with the fact that its numerical value depends on the position occupied by any of the digits used in this system. The binary number system is the simplest, since it uses only two digits: 0 and 1, and the octal number system is convenient in that its base, namely the numerical value 8, is the power of the base of the binary number system 2. For example, the decimal number 65 can be introduce

In decimal number system:

6 x 101 + 5 x 100 = 65;

in octal system as

1 x 82 + 0 x 81 + 1 x 80 = 101;

and in the binary system in the form

1 x 26 + 0 x 25 + 0 x 24 + 0 x 23 + 0 x 22 + 0 x 2l + 1 x 20 = 100,001.

Each action to be performed by the computer is given in machine language as a command. A command is information presented in a form that allows it to be entered into a machine and determines the actions of the computer over a certain period of time. Thus, each command defines, generally speaking, some elementary part of the information processing process, called a machine operation. The initial information for processing is supplied, as a rule, by a set of specific values, usually called data. The initial data for performing any action, including a machine operation, will be called operands.

In the general case, a command must indicate the type of action, the location in the machine (address) of the initial information on which the machine operation is performed, the address of the result, and the next command to be executed after this one. For arithmetic operations (or operations), the initial information is specified, as a rule, in the form of two numbers, therefore, two addresses must be specified for it in the command. Thus, an instruction must contain an operation code that specifies the type of machine operation to be performed, and four addresses: two addresses of operands, the address of the result, and the address of the next instruction. As a rule, the required number of addresses in a command is less than four.

In a computer with three-address commands, the address of the next command is not indicated, but the command is automatically executed from the next memory cell (with a number one greater, which is the address of the next command). For example, if we accept code 01 for the addition operation, then to add two numbers from cells numbered 2051 and 2052 with the result placed in cell number 2345, in a three-address machine, the command will look like this:

01 2051 2052 2345 26

The first improvement in the programming process was the introduction of symbolic addresses, which made it possible to compose instructions and allocate memory separately. The essence of this technique lies in the partition of the machine's RAM into arrays, the number of cells in which is not known in advance, and the numbers of the array cells are given by alphanumeric designations such as ai + 1, ai + 2, . . ., called symbolic addresses. Memory allocation is carried out by assigning numerical values ​​to all ai after the program has been compiled. The latter process is purely mechanical and can be automated, i.e. assignment of true addresses can be entrusted to the computer itself.

This improvement in the programming process soon led to the creation of symbolic programming languages, or autocodes. Such a language differs from the machine language only in that instead of numerical values ​​expressing the instruction's operation code and its address, symbolic (alphabetic) designations are used. Therefore, in the first autocodes, there was a one-to-one correspondence between the operations written in the symbolic programming (or coding) language and the commands in the machine language, as indicated by the 1: 1 symbol, which was written after the name of the language. For example, AUTOCODE 1:1 - AUTOMATIC Coding one to one.

Further improvement of autocodes was expressed in the appearance of additional tools that establish the order of actions in arithmetic formulas according to the usual rules or provide, under necessary conditions, branching of the computational process, cyclic repetition of program sections and other operations arising from the condition of the problem. So, gradually, autocodes lost the prefix 1: 1, and their input languages ​​​​became not purely machine, but machine-oriented. Machine-oriented means that these languages ​​continued to be based on the command system of a particular computer. The first machine-oriented languages ​​were generally imperfect. In some languages, the description of the sequence of calculations was divorced from the formulas themselves, others had complex symbolism, little visual or too specialized, and others were adapted only to solve a limited range of problems. The main drawback was the attachment of the language to this machine.

With the advent of second-generation machines, the need arose to create languages ​​that are entirely focused on the features of tasks and do not depend on a specific machine. This requirement was aggravated by the fact that computers of different brands quickly replaced one another or were used together. Problem-oriented programming languages ​​became the symbol of the second generation of computers. Their development was increasingly determined by the specifics of the tasks, and not by the characteristics of the machines. What came to the fore was what was common in various tasks, and this brought together different languages ​​created in the era of the dominance of computational tasks. These languages ​​are usually called formal algorithmic or simply algorithmic languages.

Much is required of a formal algorithmic language. First, it must be visual, which can be achieved using existing mathematical symbols and other easily understood visual means. Secondly, flexible, so that any algorithm can be described without excessive complication associated with insufficient visual means. Thirdly, the language is required to be unambiguous - the record of any algorithm, made in compliance with all the rules of the language, should not allow different interpretations. Fourth, multi-stage - a complex algorithm can be described as a combination of simpler algorithms. And, finally, the language must be unified - on the one hand, the number of visual means should not be too large, and, on the other hand, it is necessary that the same means can be used to express the same or related concepts in different ( according to their purpose) parts of the algorithm. This language is:

means of thinking - the logical imperfection of the proposed method for solving the problem is often revealed in the process of writing this method using the algorithmic language;

a means of communication between people - a description of the process performed by one person should be available to others;

An intermediary between a person and a machine - in this case, the translation from the algorithmic language into the language of the machine is performed by the machine itself using a special program - a translator.

One of the first and most successful languages ​​of this kind was Fortran, developed by IBM. In 1954, a group of American programmers published the first report on the Fortran language. The name of the language comes from the phrase FORmulae TRANslation - the transformation of formulas. The Fortran language has not only existed to this day, but also confidently holds the first place in the world in terms of prevalence. Among the reasons for such longevity, one can note the simple structure of both Fortran itself and the translators intended for it. A Fortran program is written as a sequence of sentences, or operators (an operator is a description of some information transformation), and is drawn up according to certain rules. These rules impose restrictions, in particular, on the form of recording and the location of parts of the operator in the line of the form for recording operators. A program written in Fortran is one or more segments (subroutines) of statements. The segment that controls the operation of the entire program as a whole is called the main program.

Fortran was conceived for use in scientific and engineering computing. However, this language easily describes tasks with branched logic (modeling of production processes, solving game situations, etc.), some economic tasks, and especially editing tasks (drawing up tables, summaries, statements, etc.).

A modification of the Fortran language, which appeared in 1958, was called Fortran II and contained the concepts of a subroutine and general variables to provide communication between segments.

By 1962, the emergence of a language known as Fortran IV and which has become the most common at the present time. By the same time, the beginning of the activities of the commission at the American Standards Association (ASA), which developed (by 1966) two standards - the Fortran languages ​​and the basic (basic) Fortran (Basic FORTRAN), dates back to the same time. These languages ​​roughly correspond to modifications IV and II, but basic Fortran is a subset of Fortran, while Fortran II is not a subset of Fortran IV.

The Fortran language still continues to develop and improve, influencing the creation and development of other languages. For example, Fortran is the basis of the interactive language Basic and its extension Basic-plus, widely used languages ​​in all time-sharing systems, languages ​​for teaching the skills of using algorithmic languages ​​in programming practice. These languages ​​are implemented in particular on personal computers. Currently, a new standard has been created - Fortran 77.

Shortly after the creation of Fortran (1957), the Algol language (ALGOritmic Language - an algorithmic language) appeared, created on the basis of extensive international cooperation. In 1960, an official communication was published on an algorithmic language called Algol-60, where the number 60 indicates the year the language was approved.

Algol-60 was created after the development and practical application of Fortran, therefore it is characterized by both the introduction of new constructions and the generalization of the concepts available in Fortran. For example, if in Fortran operators are functionally divided into executable and non-executable ones, then in Algol there is no such division, and the role of non-executable Fortran operators is played by constructions called descriptions.

There are other differences as well. However, Fortran and Algol have in common the fact that both languages ​​are based on the concept of an expression, which practically coincides with the concept of a mathematical expression that uses only algebraic operations and elementary functions. The simplest objects from which expressions are composed are integer and approximate real numbers and logical values.

Algol is widely recognized as a very convenient tool for publishing algorithms and for teaching the basics of programming.

Until recently, both Fortran and Algol-60 rightfully deserved the title of universal languages, since they ensured the programming of the bulk of scientific and technical problems (mainly computational). But none of these languages, of course, made it possible to describe all the problems that arose without exception. Therefore, at about the same time, algorithmic languages ​​with a different orientation appeared, meeting the needs of those new areas of science and technology that began to develop intensively in subsequent years.

An example is economic tasks - the tasks of accounting for material assets, manufactured products, personnel, finances, etc. businesses or industries. For such tasks, the main actions are input and output operations with a relatively small number of simple calculations, as well as sequential processing of data arrays. The description of actions of this kind can be carried out in the COBOL language (COMmon Business Oriented Language), proposed by IBM in 1959.

The problems of processing symbolic information arise mainly in the field of scientific research. This, for example, is the transformation of formulas, the solution of equations (not numerical, but in an analytical form), the analysis and synthesis of texts in an artificial or natural language (in particular, automatic programming and machine translation), etc.

Of the languages ​​for processing symbolic information, the Lisp language, created by a group of researchers in 1960 at the Massachusetts Institute of Technology, is very popular, mainly among representatives of the physical and mathematical sciences. In this language, all information being processed, including the program itself, is organized into so-called lists - sequences of elements. An element can be a primary (letter or number) or in turn a list. In this way, arbitrarily complex structures can arise.

Another language - Snobol - is mainly used for machine analysis of texts written in natural languages. In it, the main concept is a string - an arbitrary sequence of letters, numbers and other characters. The main operation is to search in a string for a part of a string built according to a given image, and to replace this part with another string. Both the image and the lines that replace it are composed of separate elements of a simple form. The outcome of the search determines the sequence of further actions. The Snobol language is very easy to learn.

The main advantage of problem-oriented, machine-independent algorithmic languages ​​is that they were built with maximum consideration of human ideas, if not about the essence, then about the form of the problem being solved, with the maximum approximation to the form in which a person is used to describing these problems, and taking into account those logical connections that he learned to single out in the phenomena under study.

Algol, for example, is characterized by an approximation to the usual mathematical symbolism. Fortran, unlike Algol, is closer to machine language than to human language. Lisp is characterized by the use of the apparatus of so-called recursive descriptions, which is widely used in mathematical logic, in research on the foundations of mathematics, and so on.

The abundance of algorithmic languages ​​that appeared during the second generation of computers, on the one hand, is largely due to fashion, on the other hand, the impossibility of any of the proposed languages ​​to conveniently describe all the problems that arose. The third generation of computers put on the agenda the development of a new approach to the creation of a truly universal algorithmic language.

One of the attempts of this kind is the creation by IBM of the algorithmic language PL / 1 (Programming Language / 1 - programming language one). It is based on the Fortran and Cobol languages, a number of figurative means and concepts are taken from Algol and other languages, in particular, languages ​​for processing symbolic information. Then several versions of the language were published in succession, which differed greatly from each other, but gradually the language stabilized, and now new publications differ from previous ones only by editorial corrections, elimination of inaccuracies or improvement of individual elements.

The main elements of a program written in the PL/1 language are operators that describe both data and operations for processing them. By analogy with Fortran, the source program is a combination of the main program and subroutines that have the form of a block. The concept of a block in PL/l is based on the concepts of a block in the Algol-60 language. Thus, this language is generally built on the basis of the concepts of existing algorithmic languages ​​and in their traditions.

Another attempt is connected with the further development of Algol. In 1968, a document was published outlining the foundations of a new universal algorithmic language, called Algol-68. In this language, the number of basic concepts is reduced to a reasonable minimum in order to achieve a high figurative power of the language, ensuring the freedom of combination and interaction of these concepts with each other.

The Algol-68 language is traditional, since there is a desire to provide all users with ready-made tools for describing their algorithms. Until now, this approach could not prevent the emergence of more and more specialized languages. So, in 1971, the algorithmic language Pascal was published, named after the great French scientist of the 17th century, who was the first in the world to invent an automatic device that allows you to add numbers. The Pascal language is the successor of Algol-60, it has constructions similar to those in PL/l and Algol-68, but Pascal is more concise. The language Pascal is almost as simple as BASIC, however, Pascal facilitates the introduction of modern programming technology based on the incremental building of a program, consisting of small, well-defined procedures, i.e. the ideas of structured programming are consistently put into practice. Another essential feature of Pascal is the concept of a data structure as one of the fundamental concepts that, along with the concept of an algorithm, underlies programming.

Based on the Pascal language, the Ada language was created in the late 70s, which has a very wide scope. The language is named after the first female programmer, Ada Lovelace. The algorithmic language of Ada has undergone certain changes in the course of evolution and now has all the hallmarks of a standard language. It is a highly structured language, and is particularly suited to the development of real-time systems. However, the Ada language is too cumbersome, verbose and does not provide the programmer with sufficient freedom.

Unlike these high-level languages ​​that appeared in the early 80s, the C programming language is a relatively low-level language. But this does not mean that this language is not powerful enough. The C language is a general-purpose language closely related to the popular UNIX operating system (the UNIX system and its software are also written in C). The algorithmic C language fully reflects the capabilities of modern computers, allowing you to write very efficient programs without resorting to assembly languages, mainly due to simple, sequential control flow constructs. Checks, loops, grouping and subprograms are offered, but not multiprogramming, parallel operations, synchronization and coroutines - indispensable attributes of powerful languages ​​(Ada, PL/1, Algol-68).

Recently, there has been a trend towards the creation of so-called extensible universal languages. The main idea of ​​this direction is not to avoid specialized languages-dialects, but to create a common basis for "programming dialects".

The language being extended must have the means to parse the texts of any of the extensions in order to find out which texts are grammatically correct for a given dialect and what structure they have. Such a language should give its future users a number of important features: for example, to build semantic models (i.e., introduce new terms to describe the concepts they express, their relationship with some basic, original concepts and concepts introduced earlier), describe the implementation of extensions - ways of their most expedient representation with the help of the means available to modern computers. Other characteristic features of extensible languages ​​can also be noted.

^

Programming languages ​​and systems

  1. Development of programming languages

Generations of programming languages

Programming languages ​​are usually divided into five generations.

^ In the first generation includes languages ​​created in the early 50s, when the first computers first appeared. It was the first assembly language created on the principle of "one instruction - one line".

heyday second generation programming languages ​​came in the late 50s - early 60s. Then a symbolic assembler was developed, in which the concept of a variable appeared. It became the first full-fledged programming language. Thanks to its appearance, the speed of development and reliability of programs have noticeably increased.

Appearance third generation programming languages ​​are usually attributed to the 60s. At this time, universal high-level languages ​​arose, with their help it is possible to solve problems from any area. Such qualities of new languages ​​as relative simplicity, independence from a particular computer and the ability to use powerful syntactic constructions, made it possible to dramatically increase the productivity of programmers. The structure of these languages, understandable to most users, attracted people to write small programs (usually of an engineering or economic nature). The vast majority of languages ​​of this generation are successfully used today.

From the beginning of the 70s to the present, the period of languages ​​continues fourth generation. These languages ​​are designed to implement large projects, increase their reliability and speed of creation. They are focused on specialized areas of application, where good results can be achieved using not universal, but domain-specific languages, operating with specific concepts of a narrow subject area.

As a rule, powerful operators are built into these languages, which allow one line to describe such functionality, which would require thousands of lines of source code in the languages ​​of lower generations.

Birth of languages fifth generation happened in the mid 90s. These also include systems for automatically creating application programs using visual development tools, without programming knowledge.

The main idea that is embedded in these languages ​​is the ability to automatically generate the resulting text in universal programming languages ​​(which then needs to be compiled). Instructions are entered into the computer in the most visual form using methods that are most convenient for a person who is not familiar with programming.

^ Overview of high-level programming languages

Fortran (Fortran)

It is the first compiled language created in the 50s.

Programmers who developed programs exclusively in assembler expressed serious doubts about the possibility of a high-performance high-level language, so the main criterion in the development of Fortran compilers was the efficiency of the executable code. Although Fortran was the first to implement a number of important programming concepts, the convenience of creating programs was sacrificed for the possibility of obtaining efficient machine code. However, a huge number of libraries have been created for this language, ranging from statistical complexes to satellite control packages. Fortran continues to be actively used in many organizations. There is a standard version of Fortran HPF (High Performance Fortran) for parallel supercomputers with multiple processors.

Cobol (Cobol).

This is a compiled language for application in the economic field and solving business problems, developed in the early 60s. It is very "verbose" - its operators sometimes look like ordinary English phrases. Cobol has implemented very powerful tools for working with large amounts of data stored on various external media. A lot of applications have been created in this language, which are still in use today.

Algol (Algol). Compiled language created in 1960. It was intended to replace Fortran, but due to its more complex structure, it was not widely used. In 1968 A version of Algol 68 was created, which, in terms of its capabilities, is still ahead of many programming languages, but due to the lack of sufficiently efficient computers, it was not possible to create good compilers for it in a timely manner.

Pascal (Pascal)

The Pascal language, created in the late 70s, resembles Algol in many respects, but it tightens a number of requirements for the program structure and has features that allow it to be successfully used when creating large projects.

Basic (Basic)

There are both compilers and interpreters for this language, and it ranks first in popularity in the world. It was created in the 60s as an educational language and is very easy to learn.

C (Ci)

This language was created in the Bell laboratory and was not initially considered as a mass language. It was planned to replace assembler in order to be able to create equally efficient and compact programs, and at the same time not depend on a particular type of processor. C is in many ways similar to Pascal and has additional facilities for direct memory manipulation (pointers). Many applied and system programs and a number of well-known operating systems (Unix) were written in this language in the 70s.

C++ (C++)

C++ is an object-oriented extension of the C language, developed in 1980. It has many powerful new features that have dramatically increased programmers' productivity, but creating complex and reliable programs requires a high level of professional training from developers.

Java (Java)

This language was created by Sun in the early 90s based on C++. It is designed to simplify the development of applications based on C++ by eliminating all low-level features from it. But the main feature of this language is compilation not into machine code, but into platform-independent bytecode (each command occupies one byte). This bytecode can be executed using an interpreter - the JVM (Java Virtual Machine), versions of which are created today for any platform.

Particular attention in the development of this language is given to two areas:


  • support for all kinds of mobile devices and microcomputers built into household appliances (Jini technology);

  • creation of platform-independent software modules capable of running on servers in global and local networks with various operating systems (Java Beans technology).
So far, the disadvantage of this language is its low performance.

^ Database programming languages

This group of languages ​​differs from algorithmic languages ​​primarily in the tasks they solve. A database is a file (or a group of files) that is an ordered set of records that have a uniform structure and are organized according to a single template (usually in a tabular form). A database can consist of several tables. It is convenient to store various information in databases from directories, file cabinets, accounting journals, etc. When working with databases, you most often need to perform the following operations:

The first databases appeared a very long time ago, as soon as there was a need to process large amounts of information and select groups of records according to certain criteria. To do this, the Structured Query Language (SQL) was created. It is based on powerful mathematical theory and allows you to perform efficient database processing by manipulating not individual records, but groups of records.

DBMS (Database Management Systems) have been developed to manage large databases and process them efficiently.

In fact, in almost every DBMS, in addition to supporting the SQL language, there is a unique language that is focused on the features of this DBMS and is not portable to other systems.

Today, there are five leading DBMS manufacturers in the world:

Microsoft (SQL Server), IBM (DB2), Oracle, Software AG (Adabas), Informix and Sybase. Their products are aimed at supporting thousands of users on the network at the same time, and databases can be stored in a distributed form on several servers.

With the advent of personal computers, so-called desktop DBMS were created. The ancestor of modern database programming languages ​​for PCs is considered to be the dBase II DBMS, the language of which was interpreted. Then compilers were created for it, FoxPro and Clipper DBMS appeared, supporting dialects of this language. Today, similar but incompatible versions of the dBase family of languages ​​are implemented in Microsoft's Visual FoxPro and Inprise's Visual dBase.

^ Programming languages ​​for the web

With the active development of the global network, many popular programming languages ​​have been created, adapted specifically for the Internet.

All of them differ in characteristic features: languages ​​are interpreted, interpreters for them are distributed free of charge, and the programs themselves are in source texts. Such languages ​​are called scripting languages.

HTML. A well-known language for paperwork. It is very simple and contains elementary commands for formatting text, adding pictures, setting fonts and colors, organizing links and tables. All Web pages are written in HTML or use its extensions.

perl. In the 80s, Larry Wall developed the Perl language. It was conceived as a tool for efficient processing of large text files, generation of text reports and task management. Perl is much more powerful than languages ​​like C. It includes many commonly used functions for working with strings, arrays, all kinds of data conversion tools, process management, system information, etc.

VRML. In 1994 The VRML language was created to organize virtual three-dimensional interfaces on the Internet. It allows you to describe in text form various three-dimensional scenes, lighting and shadows, textures (coverings of objects), rotate in any direction, scale, adjust lighting, etc.

^ Modeling languages

When creating programs and forming database structures, formal methods of their representation are often used - formal notations, with which you can visually represent database tables, fields, program objects and the relationship between them in a system that has a specialized editor and program source code generator based on the created models. Such systems are called CASE systems. They actively use IDEF notations, and recently UML is becoming more widespread.

      1. ^

        Modern programming systems

Fundamentals of Visual Interface Programming

One of the dead ends or crises of programming, not so long ago, was associated with the development of a graphical user interface. Programming manually all sorts of windows, buttons, menus familiar to the user, handling mouse and keyboard events, including images and sound in programs required more and more time for the programmer. In some cases, this entire service began to occupy up to 80-90% of the volume of program codes. Moreover, all this work often disappeared almost in vain, because after a year or two the generally accepted style of the graphical interface changed and everything had to be started all over again.

The way out of this situation was indicated by two approaches.

The first is the standardization of many interface functions, which made it possible to use the libraries available, for example, in Windows. As a result, when changing the style of the graphical interface (for example, when moving from Windows 3.x to Windows 95), applications were able to automatically adapt to the new system without any reprogramming.

The second revolutionary step was the advent of visual programming, which originated in Visual Basic and found a brilliant embodiment in Delphi and Borland's C ++ Builder.

Visual programming has reduced the design of the user interface to simple and visual procedures that make it possible to do in minutes or hours what previously took months of work.

Example. In Delphi it looks like this. You work in the Delphi Integrated Development Environment, which provides you with forms (there may be several in an application) on which components fit. This is usually a windowed form, although there may be invisible forms. Icons of components available in Delphi libraries are transferred to the form with the help of the mouse and placed. With simple manipulations, you can resize the location of these components. At the same time, the result is visible all the time in the design process - the image of the form and the components located on it. Design results can be seen without even compiling the program.

The main advantage lies in the fact that during the design of the form and the placement of components on it, Delphi automatically generates program codes, including in it the appropriate fragments that describe this component. And then, in the appropriate dialog boxes, the user can change the default values ​​of the components and, if necessary, write some event handlers. In fact, design comes down to placing components on the form, setting some of their properties, and writing event handlers, if necessary.

Components can be visual, visible when the application is running, and non-visual, performing certain service functions. Visual components are immediately visible on the screen during the design process in the same way that the user will see them during application execution.

Many types of components are included in Delphi's visual component libraries, and their nomenclature expands very quickly from version to version. What is already available is enough to build almost any most intricate application without resorting to the creation of new components. With this, even an inexperienced programmer can create applications that look professional.

^ Basic Programming Systems

Of the universal programming languages ​​today, the following are the most popular: BASIC (Basic), Pascal (Pascal), C ++ (C ++), Java (Java).

For each of these programming languages, today there are many programming systems produced by various companies and focused on various PC models and operating systems.

The most popular visual RAPs for Windows are:


  • Basic: Microsoft Visual Basic;

  • Pascal: Borland Delphi

  • C++: Borland C++Bulider;

  • Java: Symantec Cafe.
To develop server and distributed applications, you can use the Microsoft Visual C ++ programming system, Borland products, and almost any Java programming tools.
    1. ^

      Software systems architecture

While most stand-alone applications - office programs, development environments, text and image preparation systems - run on a single computer, large information complexes (for example, an enterprise automation system) consist of tens or hundreds of individual programs that interact with each other over a network running on different computers. In such cases, they are said to run on a different software architecture.


  1. standalone applications. They work on the same computer.

  2. Applications in a file-server architecture. The computers of the users of the system are networked, and on each of them (at the client site) copies of the same program are running, which access the server for data, which stores files that are simultaneously available to all users (as a rule, these are databases). The server has increased reliability, high speed, large memory, it has a special server version of the operating system. When several programs access the same file at the same time, for example, in order to update it, problems may arise due to the ambiguity in determining its contents. Therefore, each change to a public file is allocated to a transaction (an elementary data processing operation that has a fixed start, end (successful or unsuccessful completion) and a number of other characteristics). The peculiarity of this architecture is that all calculations are performed on client sites, which requires the presence of sufficiently productive PCs on them (these are the so-called systems with a thick client - a program that performs all the processing of information received from the server).

  3. Applications in client-server architecture . This architecture is similar to the previous one, only the server, in addition to simply providing simultaneous access to data, is also capable of executing programs that take on a certain amount of computation (in the file server architecture, it is implemented entirely on client installations). Thanks to this, it is possible to increase the overall reliability of the system, since the server is much more stable than a PC, and remove unnecessary load from the client sites that can be used. Applications run on them perform small amounts of calculations, and sometimes only display information received from the server, which is why they are called thin clients.

  4. Applications in multi-link architecture. The disadvantage of the previous architecture is that the load on the server increases dramatically, and if it fails, the operation of the entire system stops. Therefore, a so-called application server is added to the system, on which all the computational work is performed. Another database server processes user requests, a third one can have a special program installed - a transaction monitor, which optimizes transaction processing and balances the load on servers. In most practical cases, all servers are connected in series, and the failure of one link, if not stopping all work, then at least reduces the performance of the system.

  5. Applications in distributed architecture. To avoid the shortcomings of the considered architectures, special technologies were invented that allow creating a program as a set of components that can be run on any servers connected to the network (components are, as it were, distributed over the network). The main advantage of this approach is that when any computer fails, special monitor programs that monitor the correct operation immediately restart the temporarily missing component on another computer. At the same time, the overall reliability of the entire system becomes very high, and the computational load is distributed among the servers in an optimal way. Access to the capabilities of any component designed to communicate with the user is carried out from an arbitrary client site. Since all calculations take place on servers, it becomes possible to create ultra-thin clients - programs that only display information received from the network and require minimal computer resources. Thanks to this, access to the component system is possible not only from a PC, but also from small mobile devices. A particular case of the component approach is access to server applications from browsers via the Internet.
Three component technologies are most popular today: OMG's CORBA, Sun's Java Beans, and Microsoft's COM+.

These technologies will determine the development of the information industry in the coming decades.

Programming languages it is a formal sign system designed to describe algorithms in a form that is convenient for the performer.

Classification of programming languages

Program is a detailed and complete description of the algorithm by means of a programming language. The executor of the program is a computer. To be executed by a computer, a program must be represented in machine code - a sequence of numbers understood by the processor. It is quite difficult to write a program in machine codes manually. Therefore, today almost all programs are created using programming languages, which, in their syntax and semantics, are close to natural human language. This reduces the complexity of programming. However, program text written in a programming language must be converted to machine code. This operation is performed automatically by a special utility called translator. Interpreter translates each statement of the source program in turn into machine code, checks the correctness of the statement of the statement and immediately executes it. Unlike the interpreter compiler translates the entire source program into machine language.

Examples of utility programs - interpreters are GW Basic, Logo, school algorithmic language, many database programming languages. Compilers are Turbo Pascal, С++, Delphi.

There are two approaches to program development:

    procedural programming is programming in which the execution of program commands is determined by their sequence, jump commands, loop commands, or calls to procedures;

    object-oriented programming - programming in which program objects are formed that have a set of properties, have a set of methods and are able to respond to events that occur both in the external environment and in the object itself (mouse click, timer expiration, numerical limit exceeded, etc.). d.). Thus, the execution of one or another part of the program depends on events in the software system.

Object-oriented programming (OOP) does not exclude, but embraces the technology of procedural programming.

Main programming languages

Of the universal programming languages, the most popular are the following: Basic; Pascal; C++; Java.

There are many versions of the Basic language, implemented as both interpreters and compilers. In Russia, Basic is traditionally used in high school computer science courses. Visual programming environment Microsoft Visual Basic is used as software support for MS Office applications.

The Pascal language is compiled and widely used as an environment for teaching programming in universities. The RAD environment that inherits its main properties is the Borland Delphi environment.

For C++, the RAD environment is Borland C++ Builder. This compiled language is often used to develop software applications that require speed and economy of the program.

The Java language - an interpreted language - allows you to create platform-independent program modules that can work in computer networks with different operating systems. Its RAD environment is Symantec Cafe.

Programming system is a system for developing new programs in a particular programming language.

Modern programming systems usually provide users with powerful and convenient program development tools. . They include:

    compiler or interpreter;

    integrated development environment;

    tools for creating and editing program texts;

    extensive libraries of standard programs and functions;

    debug programs, i.e. programs that help find and fix errors in the program;

    "friendly" to the user dialog environment;

    multi-window mode of operation;

    powerful graphics libraries; utilities to work with

libraries

    built-in assembler;

    built-in help desk;

    other specific features.

Popular programming systems - Turbo Basic , Quick Basic , TurboPascal , Turbo C . Recently, programming systems focused on creating Windows applications:

    package Borland Delphi (Delphi) is a brilliant successor to the Borland Pascal compiler family, providing high-quality and very convenient visual development tools. Its exceptionally fast compiler allows you to efficiently and quickly solve almost any application programming problem.

    package Microsoft Visual Basic - a convenient and popular tool for creating Windows programs using visual tools. Contains tools for creating diagrams and presentations.

    package Borland C++ - one of the most common tools for developing DOS and Windows applications.

Programming languages ​​and systems

The concept of machine language

Machine language is a system of commands that are directly understood by the hardware of a given electronic computing system. As a consequence, the machine language is uniquely determined by the processor instruction set and computer architecture.

The processor instruction set contains:

· arithmetic-logic commands - commands for arithmetic operations on binary numbers and logical operations on binary vectors;

· control commands - commands of transition, branching, repetitions, and some other commands;

Data transfer commands - commands that exchange data between RAM and CPU;

· data input-output commands - commands with the help of which the CPU and external devices exchange data.

Each instruction contains the code of the operation it performs and information about the data addresses on which this operation is performed. In addition, a command (directly - control commands and indirectly - other commands) contains information about the address of the command that will be executed next. Thus, any sequence of commands placed in RAM is actually an algorithm written in the processor's command system - a machine program.

The most common now is the architecture of computers with a common bus. The common bus is the central information highway connecting external devices with the central processor. It consists of a data bus, an address bus, and a control bus. The data bus is designed to exchange data between RAM and external devices. The address bus carries data addresses. This tire is unidirectional. The control bus serves as a channel for exchanging control signals between external devices and the central processor.

Thus, machine language (processor language) is a set of commands, each of which describes some elementary action for converting information presented in binary code. The universal use of a binary code for representing information in a wide variety of forms leads to the fact that the program for solving even a fairly simple problem contains hundreds of machine instructions. Writing such a program using machine instructions is not easy even for a skilled programmer. Real programs consist of tens and hundreds of thousands of machine instructions. Therefore, any technology for designing a program should be based on the techniques characteristic of human thinking, operate with concepts familiar to a person from the subject area to which the task belongs.

In other words, a programmer (algorithm designer) should be able to formulate his algorithm in the language of familiar concepts; then a special program must express these concepts using machine tools, translating (translating) the text of the algorithm into the language of the machine.

This need led to the emergence of high-level programming languages ​​as languages ​​for writing algorithms intended for execution on a computer.

Machine-oriented languages

The forerunners of high-level languages ​​were the so-called machine-oriented languages ​​or autocode languages. Assembler is one of the brightest representatives of machine-oriented languages. Assembler is very close to machine language, most of its instructions are exact symbolic representations of machine instructions. The advantage is that it is no longer necessary to remember the numeric codes of the processor instructions, it is enough to know their symbolic representation. In addition, for the first time in machine-oriented languages, the concept of a variable appears as a named memory area for storing data, and with it the concept of a data type. In programs in a machine-oriented language, it becomes possible to use both numerical and textual information in a form familiar to humans.

Despite the obvious advantages of machine-oriented languages ​​over a purely machine language, writing programs in these languages ​​is still fraught with significant difficulties. Programs are very bulky and difficult to read.

High level programming languages

High-level programming languages ​​play the role of a means of communication between the programmer and the machine, as well as between programmers. This circumstance imposes many obligations on the language:

The language should be close to those fragments of natural languages ​​that provide a specific subject area of ​​human activity; (A language focused on business areas of application should contain the concepts used in this type of activity: document, account, database, etc.).

All language features must be formalized to such an extent that they can be implemented as machine programs.

A programming language is more than a means of describing algorithms: it contains a system of concepts on the basis of which a person can think about his problems, and a notation with which he can express his thoughts about solving a problem.

Program broadcast models. Translators

In general, computers are not designed to understand high-level programming languages. The hardware recognizes and executes only machine language, the program in which is nothing more than a sequence of binary numbers.

The emergence of programming languages ​​was associated with the realization of the fact that the translation of an algorithm written in an “almost” natural (algorithmic) language into machine language can be automated and, therefore, placed on the shoulders of a machine. It is important to distinguish between a language and its implementation here. The language itself is a notation, governed by a set of rules that define its vocabulary and syntax. A language implementation is a program that converts this notation into a sequence of machine instructions according to the semantic rules defined in the language.

There are two main ways to implement a language: compilers and interpreters. Compilers translate all the text of a program written in a programming language into machine code in one continuous process. This creates a complete program in machine code, which can then be executed without the participation of the compiler.

The interpreter recognizes and executes one statement (operator) of the program at a time, turning the processed statement into a machine program along the way. The difference between a compiler and an interpreter is similar to the difference between simultaneous translation of spoken language and written translation of text.

In principle, any language can be both compiled and interpreted, but in most cases each language has its own preferred way of implementing it. Apparently, this preference is something more than a tribute to tradition. The choice is determined by the language itself. Fortran, Pascal, Modula-2 mostly compile. Languages ​​like Logo, Fort almost always interpret. BASIC and Lisp are widely used in both forms.

There are two main types of compilers based on the output type:

Compiling the final executable code;

Compiling interpreted code that requires additional software to run.

The final executable code is applications implemented as EXE files, DLLs, COM components. Interpreted code includes the bytecode of JAVA programs executed by the JVM virtual machine.

The object code generated by the compiler is a data area and a machine instruction area that have addresses that are further "matched" by a link editor (sometimes called a loader). The link editor places all individually compiled object modules and statically linked libraries in a single address space.

In what follows, we will call the executable form of the program the code obtained as a result of compiling the source program.

Translation process (compilation)

A program written in a high-level programming language is called the source program, and each independent program unit that forms this program is called a program module. To convert a source program into its executable form (an executable file), the compiler performs a certain sequence of actions. This sequence depends both on the programming language and on the specific implementation of the translator itself. During translation, it is important not only to compile the program, but to get a sufficiently efficient code.

During translation, the source program is analyzed and then the executable form of this program is synthesized. Depending on the number of source program scans performed by the compiler, translators are divided into one-pass, two-pass, and translators using more than two passes.

The advantages of a one-pass compiler include high compilation speed, and the disadvantages are that, as a rule, obtaining not the most efficient code.

Two-pass compilers have become widespread. They allow the first pass to analyze the program and build information tables that are used in the second pass to generate the object code.

The figure shows the main stages performed during the translation of the source program.

The program analysis phase consists of:

· lexical analysis;

parsing;

· semantic analysis.

When analyzing the source program, the translator sequentially scans the text of the program, represented as a set of characters, parsing the structure of the program.

At the stage of lexical analysis, the main components of the program, lexemes, are identified. Tokens are keywords, identifiers, operation characters, comments, spaces, and delimiters. The lexical analyzer not only extracts tokens, but also determines the type of each token. At the same time, at the stage of lexical analysis, a symbol table is compiled, in which each identifier has its own address. This allows further analysis to use its address in the symbol table instead of a specific value (character string).

The process of extracting lexemes is quite laborious and requires the use of complex context-sensitive algorithms.

At the stage of syntactic analysis, the received lexemes are parsed in order to obtain semantically understandable syntactic units, which are then processed by the semantic analyzer. So, syntactic units are expressions, declaration, programming language operator, function call.

At the stage of semantic analysis, the processing of syntactic units and the creation of an intermediate code are performed. Depending on the presence or absence of an optimization phase, the result of semantic analysis can be an intermediate code that is further optimized or a ready-made object module.

The most common tasks solved by a semantic analyzer include:

detection of compile-time errors;

filling in the symbol table created at the stage of lexical analysis with specific values ​​that determine additional information about each element of the table;

replacing macros with their definitions;

execution of compile-time directives.

A macro is some predefined code that is inserted into the program at the compilation stage in all places where the call to this macro is indicated.

At the synthesis phase of the program, the following is performed:

· code generation;

link editing.

The code generation process consists of converting intermediate code (or optimized code) into object code. In this case, depending on the programming language, the resulting object code can be presented in an executable form or as an object module to be further processed by the link editor.

Thus, the code generation process is an integral part of the program synthesis phase, and the need to execute the linker depends on the specific programming language. It should be noted that in practice the term "code generation" is often applied to all the activities of the program synthesis phase leading to an executable form of the program.

The link editor matches the addresses of code fragments located in separate object modules: addresses of called external functions, addresses of external variables, addresses of functions and methods of each module are determined. To edit addresses, the link editor uses special loader tables created at the translation stage. After the object modules are processed by the linker, an executable form of the program is generated.

4.1. Programming systems.

The main goal of any program - description of the sequence of commands for the central processor, which must execute it. These commands must be expressed in machine code, i.e. in a language understood by the CPU. It is very difficult for a person to write programs in such a language, therefore The following approach has been taken to create programs:

The programmer writes the text in a language that is understandable and convenient for him. Then it translates it into machine language and turns it into a form convenient for the central processor and operating system.

For this purpose, special languages ​​for describing algorithms are being developed, which are called algorithmic or programming languages .

(05.12.2012)

They (algorithm.language) have a number of properties:

1. Specialization - a tool provided by a language focused on describing the tasks of subject areas of a certain type. For example: some languages ​​​​are designed mainly for numerical calculations (Pascal), others for working with textual information (LISP), others for writing system programs (C). Basically, the most common languages ​​allow you to describe the solution of various problems (therefore they are called universal), but they are most convenient for solving the problems for which they are designed.

2. The ability to write easy-to-read text that has a clear structure. This programming approach is called modular (structural) . He suggests writing separate program modules with their subsequent automated assembly into a single program. In this case, the programmer writes a program module called main (head) program . In it, he describes the sequence of execution of the remaining modules, which are called programs or features .

Due to the peculiarities of programming languages, there are four important steps in launching a program for execution :

1. Broadcast – translation of the text of program modules from algorithmic language into machine language.

2. Assembly of program modules obtained after translation into a single program.

3. Program debugging - the process of finding and eliminating errors in the text of the program.

4. Program execution.

Programming systems are designed to provide these stages.

They include the following components:

1. Dedicated text editor. Provides assistance to a person in the process of writing the text of program modules.

2. Translators. Translator is a translator from the language in which the texts of program modules are written to the machine internal language. Two types of translators:

  • Interpreters. The interpreter provides a line-by-line translation of the program text into machine language and the simultaneous execution of each command of this program. The interpreter automates all stages of launching the program for execution.
  • Compilers. The compiler translates the text of a program module into machine language without executing it. At the same time, syntactic errors made by the programmer in the text are revealed. As a result of the compiler's work, an object module is created, which is not yet ready for execution.

3. Link editor. Link editor automates the process of assembling related but separately written and translated software modules. In the course of your work he brings out errors of incorrectly specified links between modules ( for example, the presence in the text of a reference to a non-existent module) or their absence. Besides, he adds service information necessary for the operating system to subsequently control the execution of this program. The file received by the program can be executed under the control of the operating system without a programming system, therefore it is called executable (bootable) file .


4. Debugger. Debugger renders help in finding various errors in the program during its execution. These include, for example,: logical errors (an attempt to divide by zero), as well as errors associated with incorrect input data.