Les sources de Syracuse append.pps

%% syntaxe : string1 string2 append --> concatene les 2 chaines ou fusionne 2 tableaux
/append {
3 dict begin
   dup isarray {
      /tab2 exch def
      /tab1 exch def
      [ tab1 aload pop tab2 aload pop ]
   } {
      /str2 exch def
      /str1 exch def
      /result str1 length str2 length add string def
      str1 result copy pop
      result str1 length str2 putinterval
      result
   } ifelse
end
} def

%% %% fusionne 2 tableaux
%% /append {
%% 3 dict begin
%%    dup isarray {
%%       /tab2 exch def
%%       /tab1 exch def
%%       [ tab1 aload pop tab2 aload pop ]
%%    } {
%%       /str2 exch def
%%       /str1 exch def
%%       /result str1 length str2 length add string def
%%       str1 result copy pop
%%       result str1 length str2 putinterval
%%       result
%%    } ifelse
%% end
%% } def


Page composée par petitParseur[ps2html] le jeudi 4 décembre 2008.