Algorithmic programming language. A fragment of the algorithm is depicted in the form of a block diagram. Determine what value of the variable S will be printed as a result of executing the algorithm. Loading module of the program - the result of the work

Algorithmization and programming

2. Absent in procedural programming languages 2) complex

Data type.

When developing a software product, comparing the results of the program with the results of observations or results obtained experimentally refers to the stage

1)debugging and testing the program

4. Designing programs by sequentially breaking a large task into smaller subtasks corresponds to... 3) top-down design

5. The language whose name is an abbreviation for “universal symbolic code for beginners” is 4)Basic

6. The identifier table during the translation process is used to store... 3). variable and function names

7. The concept of "Polymorphism" refers to 3)modular programming technologies

8. The modular structure of the program reflects one of the features 2) dynamic programming.

10. Loading module of the program - the result of work... 4) link editor (linker)

11. The object-oriented approach is based on the concept 3)class hierarchy

12. The first stage of solving a problem on a computer is 1) problem statement

13. Data markup languages ​​are 1)HTML and XML

3)P=False;Q=False

16. The program is 2) an algorithm written in a programming language

Encapsulation in object-oriented programming means being able to

2) determination of the interface (specification) of methods for their implementation

18. Interpreters perform 1)operator-by-statement processing and program execution

The task: “enter two numbers and find their arithmetic mean and geometric mean and give the result” corresponds to an algorithm...

22. Does not apply to basic algorithmic constructions 1) substitution

The object-oriented approach to programming is based on the principle

4). bottom-up design

26. The Lisp language is a language 2)functional

Programming

27. When developing a software product, elimination of shortcomings noticed by the user is carried out at stage 4) maintenance of the software product

The basic principles of structured programming do not include

3) achieving an absolute minimum of characters and lines in the program text

29. Variable attributes in programming languages: a) name b) address c) visible/hidden d) value e) type f) functionality 2). a, b, d, d

1) number of zeros

A fragment of the algorithm is depicted in the form of a block diagram. Determine what value of the variable S will be printed as a result of executing the algorithm.

What value of the variable S will be printed after executing a fragment of the BASIC program?

For N = 1 To 3

Print S 4)6

4) finds the number of characters of the entered number

38. The definition of “suitability of an algorithm for solving a certain class of problems” refers to the property of algorithms, which is called 3) mass character

39. A translator that translates the source program into an equivalent resulting program in machine command language is called 4) Compiler

40. Procedural programming languages ​​do not have 2) complex

Data type.

41. The concept of "Polymorphism" refers to 1)object-oriented programming technologies

Database

4) is key in both tables

1)parametric

3. Relational databases represent dependent data in the form 1) interconnected tables

5. The language for querying relational databases is 1)SQL

6. In a relational database, a field is 4) column in the table

7. Based on the method of accessing databases, DBMSs are divided into 2). client-server

How many records are there in the presented database? 4)4

9. What entries will be found after searching in the Computer text box with the condition “contains a Pentium”?

10. In a relational database, a table field 3) table column

11. In a relational database, all elements of one column in a table 1) have the same type and length

12. Fill in the missing words in the definition: Database management system is 1) a set of software and language tools necessary to create databases, keep them up to date and organize the search for the necessary information in them.

13. Fill in the missing words in the definition: A database is 2) named and structured a collection of data related to a specific subject area.

14. In a relational database table 3)each field has a unique name

15. In what order will the records be located in the database after sorting in ascending order in the Memory field?

16. In a relational database 2) the data is presented in the form of one or more interrelated tables

17. Fill in the missing words in the definition: Field whose value 3)unambiguously identifies the corresponding entry , is called the key field.

18. When entering a condition for a date value in the Access DBMS, the correct entry is 1)>#01.01.55# And<#01.01.75#

19. A database field may contain 2) text, number and other types of data

20. The concept of a transaction corresponds to 1)Last. operations on data, which is considered in the DBMS as a single whole

2) many to many (M:M)

22. A form in Acess can be created based on 2) tables and queries

23. Relationships between tables in the MS Access DBMS are automatically established when using the Wizard 2) substitutions

Global and local networks

1. Network topology with sequential service of nodes is called 4)Ring

2) communication protocol with a remote computer

4. A computer that has 2 network cards and is designed to connect networks is called 1)router

6. The communication line with minimal delay is 2) fiber optic

7. An application for viewing hypertext pages is called 4) Browser

8. An IP address that is assigned automatically when a device connects to the network and is used until the connection session ends is called 4) Dynamic

9. FTP is 3) the name of the network protocol that serves the reception and transmission of files

4) twisted pair

11. The Open Network Interconnection (OSI) model includes 1) seven levels of interaction

1) common bus

13. Applies to browsers 1)Opera

14. The FTP protocol is designed for 1)file transfer

16. The browser is 2)web page viewer

17. Modem is 4) technical device

18. Electronic mail (e-mail) allows you to transfer 3)messages and attached files

19. A modem transmitting information at a speed of 28,800 bps can transmit two pages of text (3,600 bytes) within 3)1 seconds

20. A computer connected to the Internet must have 1)IP address

Algorithmic programming language- a formal language used to write, implement, and study algorithms. Unlike most programming languages, an algorithmic language is not tied to the computer architecture and does not contain details related to the design of the machine.

To study the basics of algorithmization, the so-called Russian algorithmic language(school algorithmic language), using words in Russian that are understandable to schoolchildren.

An Algol-like algorithmic language with Russian syntax was introduced by academician A.P. Ershov in the mid-1980s, as the basis for a “machineless” computer science course.

Basic function words of the algorithmic language

Description of the algorithm

  • alg(algorithm)
  • arg(argument)
  • res(result)
  • beginning(beginning) — the beginning of the algorithm
  • con(end) - end of the algorithm
  • given— source data in any form
  • necessary— the goal of the algorithm

Data types:

  • intact(whole)
  • things(real)
  • Sim(character)
  • lit(letter) - string
  • log(logical)
  • tab(table) - to denote an array
  • lengths(length) - number of array elements

Designation of conditions

  • If
  • otherwise
  • choice
  • value

Cycle designation

  • nc(start of cycle)
  • kts(end of cycle)
  • Bye

Logical functions and values ​​for constructing expressions

Input Output

  • input
  • conclusion

General view of the algorithm

1
2
3
4
5
6

alg name of the algorithm (arguments and results)
| given conditions for applicability of the algorithm
| necessary purpose of the algorithm
beginning description of intermediate quantities
| sequence of commands (body of the algorithm)
con

Part of the algorithm from the word alg to the word beginning is called a heading, and the part enclosed between the words beginning And con- body of the algorithm.

In a sentence alg after the name of the algorithm, the characteristics are indicated in parentheses ( arg, res) and value type ( intact, things, Sim, lit or log) all input (arguments) and output (results) variables. When describing arrays (tables), a special word is used tab, supplemented by boundary pairs at each array element index.

In the algorithm entry, keywords are usually underlined or in bold. To highlight logical blocks, indentations are used, and paired words of the beginning and end of the block are connected by a vertical bar.

Basic algorithmic structures

A detailed description of the main algorithmic structures is given in this article. Below are templates for composing these structures in algorithmic language.
Incomplete fork

| If condition
| | That actions
| All

Full fork

1
2
3
4
5

| If condition
| | That actions 1
| | otherwise actions 2
| All

Branching

1
2
3
4
5
6
7
8

| choice parameter
| | at value value 1
| | | actions 1
| | at value value 2
| | | actions 2
| | otherwise
| | | default actions
| All

Loop with precondition

| nts for now condition
| | actions
| kts

Loop with postcondition

The basic principles of structured programming do not include....

When developing a software product, elimination of shortcomings noticed by the user is carried out at the _________ stage

The Lisp language is a ____________ programming language.

The object-oriented approach to programming is based on the principle....

Does not apply to basic algorithmic constructions...

Interpreters do...

Encapsulation in object-oriented programming means being able to.....

The program is...

Data markup languages ​​are..........

The first step in solving a problem on a computer is....

The object-oriented approach is based on the concept....

The loading module of the program is the result of work...

The modular structure of the program reflects one of the features of _______________ programming.

The identifier table during the translation process is used to store...

Designing programs by sequentially breaking a large problem into smaller subproblems corresponds to...

When developing a software product, comparing the results of the program with the results of observations or results obtained experimentally refers to the stage

Procedural programming languages ​​do not have a _____________ data type.

1). symbolic

2). complex

3). integer

4). Real

1). debugging and testing the program

2). analysis and formalized description of the problem

3). program support

4). analysis of the results obtained

1). bottom-up design

2). object-oriented design

3). top-down design

4). conceptual modeling

5. The language, whose name is an abbreviation for "universal symbolic code for beginners" is...

1). variable values

2). results of function execution

3). variable and function names

4). results of procedures

7. The concept of "Polymorphism" refers to

1). object-oriented programming technologies

2). structured programming technologies

3). modular programming technologies

4). imperative programming technologies

1). heuristic

2). dynamic

3). logical



4). Structural

1). interpreter

2). grammar

3). translator

4). link editor (linker)

1). formalization of properties

3). class hierarchy

4). Recursions

1). formulation of the problem

2). testing

3). debugging

4). algorithm development

1). P=True; Q=False

2). P=False; Q=True

3). P=False; Q=False

4). P=True; Q=True

1). a complete minimal semantic expression in a programming language

2). algorithm written in a programming language

3). computer operating system command set

4). protocol for interaction between computer network components

1). implementation of the "one module - one object" correspondence

2). defining the interface (specification) of methods for their implementation

3). creating special programs that implement changes in the state of an object

4). enclosing procedures for working with an object in a separate module

1). statement-by-statement processing and program execution

2). statement-by-statement processing without program execution

3). only broadcast of the program

4). tracing and program execution

The task: “enter two numbers and find their arithmetic mean and geometric mean and give the result” corresponds to an algorithm...

1). substitution

2). branching

3). loop with precondition

4). loop with postcondition

1). dichotomous search

2). branches and bounds

3). top-down design

4). bottom-up design

1). systemic

2). functional

3). structural

4). Uncertain

1). debugging and testing

2). analysis of the results obtained

3). coding the program

4). software product support

1). top down programming

2). dividing the project into modules, each of which has one input and one output

3). achieving an absolute minimum of characters and lines in the program text

4). program logic allows only three basic algorithmic structures: sequences, branches, and repetitions

29. Variable attributes in programming languages: a) name b) address c) visible/hidden d) value e) type f) functionality

1). a B C D

2). a, b, d, d

3). b, d, d, f

4). a, c, d, d

1). number of zeros

2). number of positive

3). number of the last zero

4). number of the first zero

34. What value of the variable S will be printed after executing a fragment of the BASIC program?

| Test

Lesson 38
Test

"Algorithmization and programming"

Attention! The test contains questions and code elements from Pascal!


First option

Part 1.

1. What does an assignment sign look like in programming?:

  1. <=

2. What is the name of an algorithmic design that consists of sequential actions that follow each other in a strictly ordered order?

  1. Following
  2. Branching
  3. Repetition

3. What algorithm is shown in the picture?:

  1. Following
  2. Branching
  3. Repetition

4. Select the correct program entry :

  1. program Yakov_petrovich;
  2. program Yakov petrovich;
  3. program Yakov Petrovich;
  4. program_Yakov_Petrovich;

5. Which command can be used to find out the remainder of division of a number? aonb:

Part 2.


1. Write down the value of the variable b

a:=4;

x:=10;

a:= x-a*2;

x:=a*2-x;

2. What will happen as a result of executing this algorithm? Write down your answer :

a:=5;

b:=7;

if a>b then b:= a+b-28

elseb:= a* b-30;

3. What will happen as a result of executing this algorithm? Write down the value you get for variable b

a:=7;

b:=22;

a:= b div a;

b:= b mod a;

4. What value of b will be obtained after executing the algorithm? Write down the answer. (If you need to round your answer, round to the nearest tenth)

a:=3;

b:=90;

for i:=1 to 4 do

b:=b/a;

  1. program cup_of_tea;
  2. var a, b, c, y , x: real;
  3. begin
  4. writeln('Please enter three numbers');
  5. readln(a,b,c);
  6. y:=a;
  7. if b>y then y:=b;
  8. if c>y then y:=c;
  9. if ab) or (a>c) then x:=a;
  10. if ba) or (b>c) then x:=b;
  11. if ca) or (c>b) then x:=c;
  12. writeln(y+x);
  13. end.
  1. What is the name of the program? Write
  2. Write down what type of variables is used in the program.
  3. Write down the names of the variables used.
  4. On which line does the program receive data from the user? Write the line number
  5. What will be displayed if the user enters the values: 6, 9, 3

Part 3. Write a program.

Three numbers are entered. Print the smallest number.

Second option

Part I

1. The design of an algorithm in which, as a result of checking the fulfillment of a condition, various actions can be performed is called:

  1. Following
  2. Branching
  3. Repetition

2. Not equal in pascal it is written:

3. Which entry is correct:

  1. write (Set variables a and b);
  2. write (‘ Set Variables a and b’);
  3. write (‘ Set Variables ’, a and b);
  4. write ( Set Variables , ‘a and b’);

4. The block diagram shows the algorithmic design:

  1. Linear algorithm
  2. Branching algorithm
  3. Repetition algorithm

5. A command in pascal that allows you to read data received from the user:

  1. write

Part 2.


1. What value will the variable k have after executing this algorithm?:

a:=2;

k:=4;

a:= k+a*3;

k:=a/2-k;

2. Write down the value of the variable b after executing a fragment of the algorithm:

a:=7;

b:=5;

if a>b then b:= a+b+5

elseb:= a* b-3;

3. Write down the value of the variable b after executing a fragment of the algorithm:

a:=4;

b:=15;

a:= b div a;

b:= b mod a;

4. Write down the value of the variable b after executing a fragment of the algorithm:

a:=2;

b:=5;

for i:=1 to 5 do

b:= a* b;

5. Review the algorithm and answer the questions:

program stocking;

var a, b, c, y: real;

begin

writeln('Enter three numbers');

readln(a,b,c);

y:=a;

if b>y then y:=b;

if c>y then y:=c;

writeln( y) ;

end.

  1. Write the name of the program.
  2. What type of variables is used in the program.
  3. How many variables are used in the program, indicate their names.
  4. Rewrite the line where the program receives data from the user.
  5. What will be displayed if the user enters the values: 5, 8, 2.

Part 3. Write a program.

Given two integersaAndb ( a< b). Print in ascending order all the integers located between a andb(including the numbers themselvesaAndb), as well as the numberNthese numbers.

Continuing the topic:
Windows

There are many instant messaging systems available for the iOS operating system, one of which is WhatsApp. This application allows you to send messages...