Предмет: Информатика, автор: wgwarfa86

Помогите с информатикой пожалуйста
Напишите программу,
прибавляющую ко всем
элементам массива по
единице. Выведите на
экран оба массива.


lozromanik: На каком языке надо написать?
wgwarfa86: Pascal
lozromanik: Ых
lozromanik: массив заполняет польщователь?
politerhon: хороший вопрос ))
politerhon: напиши оба варианта: рандом и пользовательская правка
politerhon: один закоментируй

Ответы

Автор ответа: politerhon
3

program znanija;

const N = 8;//Количство элементов массива, задаешь любое

//значение от 0 до бесконечности

var

i:integer;

arr: array[0..N]of integer;

begin

for i:=0 to N do

arr[i]:=random(100);

writeln(arr);

//прибавление едениц к каждому элементу

for i:=0 to N do

arr[i]:=arr[i]+1;

writeln(arr);

end.

Приложения:

politerhon: Надеюсь помог
wgwarfa86: спасибо большое
Похожие вопросы
Предмет: Английский язык, автор: t0409
1. Complete the sentence, using right tense form: He _____to the University by bus every day.

A) come
B) comes
C) does come
D) is coming
E) coming

2. Choose the correct variant: I haven’t seen my friend for ages, he says.

A) He says he hadn’t seen his friend for ages
B) He says he will seen his friend for ages
C) He says he wasn’t seen his friend for ages
D) He says he hasn’t seen his friend for ages
E) He says he isn’t seen his friend for ages

3. Choose the correct answer: If the chairman ... ill, the meeting wouldn't have been cancelled.

A) hadn't been
B) wouldn't be
C) won't be
D) wasn't
E) wouldn't have been

4. Choose the right modal verb: He … smoke so much.

A) should
B) Need
C) May
D) shouldn’t
E) Might

5. Choose the right variant: I had ….friends at the University.

A) much
B) a little
C) a few
D) little
E) more

6. Water _____ at 100 degrees.

A) have boiled
B) will have been boiling
C) will boil
D) Boils
E) is boiling

7. Choose the correct answer: If it (to snow), the children will play snowballs.

A) will snow
B) will snows
C) snows
D) would snows
E) snowing


8. Choose the right possessive pronoun: This is a bedroom. …walls are green.

A) His
B) its
C) itself
D) her
E) their

9. Choose the right antonym to the word expression: to be strong in-

A) to be good at
B) to be great
C) to be weak in
D) to be educated
E) to be strict

10. Choose the appropriate formula of the Present Perfect Tense:

A) shall/will + V
B) am/is/are + V-ing
C) had + V-3
D) V2
E) have/has + V3
Предмет: Алгебра, автор: mobfire98