C++
#include <iostream>#include <vector>int main () { int a, b, c; std::cin >> a >> b >> c; std::vector list {a, b, c}; bool is_it_correct = std::find_if(list.begin(), list.end(), [](auto el){ return el > 0; }) != list.end() && std::find_if(list.begin(), list.end(), [](auto el){ return el < 0; }) != list.end(); if (is_it_correct) std::cout << "YES" << std::endl; else std::cout << "NO" << std::endl;}
var str:string;
A,B,i:integer;
begin
write('введите ваш текст');
readln(str);
for i:=1 to length(str) do begin
if (str[i]='А')or (str[i]='а') then a:=a+1;
if (str[i]='Б')or (str[i]='б') then B:=b+1;
end;
if (A+B)=0 then write('нет таких букв') else write ('A= ',A,' Б= ',b);
end.
вариант 3
var str:string;
A,B,i:integer;
begin
write('введите ваш текст');
readln(str);
i:=1;
while i<=length(str) do begin
if (str[i]='А')or (str[i]='а') then delete(str,i,1);
i:=i+1;
end;
write(str);
end.