uses crt;
var kitu,chuoi: string;
n,i:integer;
begin
clrscr;
n:= 0;
write('Nhap 1 chuoi bat ki: ');readln(chuoi);
write('Nhap 1 ki tu bat ki: ');readln(kitu);
for i:= 1 to length(chuoi) do
if kitu = chuoi[i] then n:= n + 1;
write('So lan xuat hien cua ',kitu,' trong chuoi la: ', n);
readln
end.