The number X is entered from the keyboard.Fill the array with 10 elements, in which: the first is 1

The number X is entered from the keyboard.Fill the array with 10 elements, in which: the first is 1 less than X, the second is 2 less than X, … etc., the tenth is 10 less than X. (pascal)

program zz1;
const n = 10; // set the number of elements in the array
var i, x: integer; // set variables of integer type
m: array [1..n] of integer;
begin
write (‘enter the given number X’); // enter the specified number from the keyboard
read (x);
for i: = 1 to n do // get n numbers according to the condition and write them into an array
m [i]: = x – i;
writeln (‘Received array:’); // go to a new line to display the response
for i: = 1 to n do // display the resulting array on the screen in a string
write (m [i], ”);
end.



One of the components of a person's success in our time is receiving modern high-quality education, mastering the knowledge, skills and abilities necessary for life in society. A person today needs to study almost all his life, mastering everything new and new, acquiring the necessary professional qualities.