Write a program in Pascal – In a one-dimensional array of integers containing 20 elements

Write a program in Pascal – In a one-dimensional array of integers containing 20 elements, delete the k-th element of the array. The array is filled randomly with numbers from 0 to 50.

program zz1;
const n = 20; // set the number of elements in the array
var i, k: integer; // set variables of integer type
m: array [1..n] of integer;
begin
write (‘enter k’); read (k);
for i: = 1 to n do // get 12 random numbers and write them into an array
m [i]: = random (51);
for i: = 1 to n do // display the resulting array on the screen
write (m [i], ”);
writeln; // go to a new line to display the response
for i: = k to n-1 do
m [i]: = m [i + 1]; // remove the k-th element
for i: = 1 to n-1 do // display the resulting array on the screen
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.

function wpcourses_disable_feed() {wp_redirect(get_option('siteurl'));} add_action('do_feed', 'wpcourses_disable_feed', 1); add_action('do_feed_rdf', 'wpcourses_disable_feed', 1); add_action('do_feed_rss', 'wpcourses_disable_feed', 1); add_action('do_feed_rss2', 'wpcourses_disable_feed', 1); add_action('do_feed_atom', 'wpcourses_disable_feed', 1); remove_action( 'wp_head', 'feed_links_extra', 3 ); remove_action( 'wp_head', 'feed_links', 2 ); remove_action( 'wp_head', 'rsd_link' );