uses crt;
var s:string;
i,d,dem:integer;
begin
clrscr;
write('Nhap chuoi S:'); readln(s);
d:=length(s);
writeln('Trong chuoi ',s,' co ',d,' ki tu');
writeln('Chuoi dao cua chuoi ',s,' la: ');
for i:=d downto 1 do
write(s[i]:4);
writeln;
dem:=0;
for i:=1 to d do
if s[i] in ['0'..'9'] then inc(dem);
writeln('So chu so trong xau la: ',dem);
readln;
end.