FX:EURCHF   Euro / Swiss Franc
procedure TForm22.N71Click(Sender: TObject);
var n,b,par,impar,np,ni : Integer;
begin
n:=StrToInt(Edit1.Text);
par:=1; impar:=1; np:=0; ni:=0;
while n>0 do
begin
b:=n mod 10;
n:=n div 10;
if b mod 2=0 then
begin
np:=np+b*par;
par:=par*10;
end
else
begin
ni:=ni+b*impar;
impar:=impar*10;
end;
end;
Edit2.Text:=IntToStr(np);
Edit3.Text:=IntToStr(ni);
end;
end.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.