function Encode(Str:String):String;
var//加密
TmpChr:AnsiChar;
i,Len:integer;
begin
Result:=Str;
Len:=Length(Result);
TmpChr:=Result[1];
for i:=1 to Len-1 do
Result[i]:=Result[i+1];
Result[Len]:=TmpChr;
end;
function Decode(Str:String):String;
var//解密
TmpChr:AnsiChar;
i,Len:integer;
begin
Result:=Str;
Len:=Length(Result);
TmpChr:=Result[Len];
for i:=Len DownTo 2 do
Result[i]:=Result[i-1];
Result[1]:=TmpChr;
end;