Задача 14 урок 13.1
Primary tabs
С помощью вложенных циклов выведите на экран таблицу деления чисел от 1 до 9.
program zadacha14; var i, j: integer; begin i := 1; repeat j := 1; repeat write(i, ':', j, '=' ,i/j:1:1, ' '); j:=j+1; until (j > 9); writeln(); i:=i+1; until (i > 9); readln(); end.
Консоль:
1:1=1.0 1:2=0.5 1:3=0.3 1:4=0.3 1:5=0.2 1:6=0.2 1:7=0.1 1:8=0.1 1:9=0.1 2:1=2.0 2:2=1.0 2:3=0.7 2:4=0.5 2:5=0.4 2:6=0.3 2:7=0.3 2:8=0.3 2:9=0.2 3:1=3.0 3:2=1.5 3:3=1.0 3:4=0.8 3:5=0.6 3:6=0.5 3:7=0.4 3:8=0.4 3:9=0.3 4:1=4.0 4:2=2.0 4:3=1.3 4:4=1.0 4:5=0.8 4:6=0.7 4:7=0.6 4:8=0.5 4:9=0.4 5:1=5.0 5:2=2.5 5:3=1.7 5:4=1.3 5:5=1.0 5:6=0.8 5:7=0.7 5:8=0.6 5:9=0.6 6:1=6.0 6:2=3.0 6:3=2.0 6:4=1.5 6:5=1.2 6:6=1.0 6:7=0.9 6:8=0.8 6:9=0.7 7:1=7.0 7:2=3.5 7:3=2.3 7:4=1.8 7:5=1.4 7:6=1.2 7:7=1.0 7:8=0.9 7:9=0.8 8:1=8.0 8:2=4.0 8:3=2.7 8:4=2.0 8:5=1.6 8:6=1.3 8:7=1.1 8:8=1.0 8:9=0.9 9:1=9.0 9:2=4.5 9:3=3.0 9:4=2.3 9:5=1.8 9:6=1.5 9:7=1.3 9:8=1.1 9:9=1.0
- Log in to post comments
- 608 reads