pascal
var
n: integer;
x, f: real;
begin
Write('Введите значение х = '); ReadLn(x);
repeat
Write('Введите номер функции 1, 2 или 3: '); ReadLn(n);
until n in [1,2,3] ;
case n of
1: f := sqr(x) + 4;
2: f := -10 * x - 1;
3: f := 7 - x;
end;
WriteLn('f(', x, ') = ', f);
end.