// PascalABC.NET 3.1, сборка 1201 от 18.03.2016
begin
var a,b,x,fx:real;
Write('Введите a b x: '); Read(a,b,x);
if x>=2 then fx:=a+b*sqr(tan(x))
else fx:=ln(abs(x/(a+b)));
Writeln('y=',cos(fx))
end.
<u><em>Тестовые решения:</em></u>
Введите a b x: 3.5 2.18 4.7
y=0.486472312761788
Введите a b x: -3 8.15 0.035
y=0.275408828695224
var
str: string;
sep: array of string := new string[1]('xyz');
begin
readln(str); <em>//str := 'xzyfffxyzffffffffffxyz xyzvv';</em>
writeln(str.Split(sep, System.StringSplitOptions.None).Length - 1, ' вхождений');
writeln(str.Remove(str.IndexOf(sep[0]) + 3, str.LastIndexOf(sep[0]) - str.IndexOf(sep[0]) - 3));
end.