Вопрос задан 26.08.2018 в 22:35. Предмет Информатика. Спрашивает Быстрова Виктория.

Составить программу для вывода в столбик таблицу умножения на 9.

0 0
Перейти к ответам

Ответы на вопрос

Внимание! Ответы на вопросы дают живые люди. Они могут содержать ошибочную информацию, заблуждения, а также ответы могут быть сгенерированы нейросетями. Будьте внимательны. Если вы уверены, что ответ неверный, нажмите кнопку "Пожаловаться" под ответом.
Отвечает Шатунова Даша.

var a:array[1..10,1..10]of integer;

i,j:integer;

begin

for i:=2 to 10 do a[i,1]:=i-1;

for i:=2 to 10 do a[1,i]:=i-1;

 

for i:=2 to 10 do

for j:=2 to 10 do

a[i,j]:=a[i,1]*a[1,j];

 

for i:=1 to 10 do begin

for j:=1 to 10 do

write(a[i,j]:3); if j=10 then writeln; end;

 

end.

0 0
Отвечает нейросеть ChatGpt. Будьте внимательны, ответы нейросети могут содержать ошибочные или выдуманные данные.

Program to Display the Multiplication Table of 9

Here is a program in Python to display the multiplication table of 9 in a column format:

```python for i in range(1, 11): print(f"9 x {i} = {9 * i}") ```

The above program uses a `for` loop to iterate through the numbers 1 to 10. For each iteration, it calculates the product of 9 and the current number (`9 * i`) and prints it in the format "9 x i = result".

The output of the program will be:

``` 9 x 1 = 9 9 x 2 = 18 9 x 3 = 27 9 x 4 = 36 9 x 5 = 45 9 x 6 = 54 9 x 7 = 63 9 x 8 = 72 9 x 9 = 81 9 x 10 = 90 ```

This program can be easily modified to display the multiplication table of any other number by changing the value of the constant (`9` in this case) in the program.

I hope this helps! Let me know if you have any further questions.

0 0

Топ вопросов за вчера в категории Информатика

Последние заданные вопросы в категории Информатика

Задать вопрос