Program tabl; {табуляция функции} var X, XN, XK, DX, Z:real; i: integer; Begin writeln ('Введите хнач., хкон., шаг '); readln (XN, XK, DX); {Вывод заголовка таблицы} writeln (' ':5,'функция z=EXP (-X)'); for i:=1 to 26 do write ('_'); writeln(); writeln ('| X | Z |'); for i:=1 to 26 do write ('-'); writeln (); {Рабочая часть программы} X:=XN; While X>=XK do Begin if x>=1 then Z:=sqrt(abs(2*x+(ln(x))*ln(x))) else if (x>-1) and (x<1) then Z:=(sqr((pi/2)-arcsin(x)))/2 else if (x<-1) then Z:=exp(2*x)*ln(sqr(x)+1/ln(10)); Writeln ('|', X:10:3, '|', Z:10:3, '|'); X:=X+DX End; {Вывод низа таблицы} for i:=1 to 26 do write ('_'); writeln (); End. 

Find and correct the error, please. These are: -4 4 0.4

  • There you have to enter 3 numbers, they are -4; four; 0.4 - Jonas Smitest
  • now semicolons come from somewhere - Igor

1 answer 1

Quiz? -4 4 0.4

If the comma - decimal - is required, read the lines and convert them to numbers using StrToFloat (or whatever is in pure Pascal for conversion taking into account Regional Settings ).