function Rot(const Str: string; const Rot: integer): string; var N,L: integer; pB,pR : ^byte; begin L := Length(Str); SetLength(result, L); pB := @Str; pR := @Result; for N := 1 to L do begin pR^ := (pB^ + Rot) mod 256; inc(pR); inc(pB); end; end;