anchor.diff:  
   map_new() -> emptymap.
   
  -map_get(FK, {map, {K,V}, L, R, D}) ->
  +map_get(FK, {map, {K,V}, L, R, _}) ->
       case comp(FK, K) of
           eq -> {ok, V};
           lt -> map_get(FK, L);
  
positive.code: delfirst([$\n|T]) -> T;
  delfirst([_|T]) -> delfirst(T).
  
  %% 複数行取得、文字列連結にならんようにタプルで囲む
  getlines() ->
      case io:get_chars("",20000) of
          eof -> eof;
          {error, E} -> {error, E};
  
negative.code: -module(main).
  -export([main/1]).
  -import(string,[concat/2,copies/2]).
  
  main(_) ->
      io:format("~s",[palindrome(getwords())]),
      halt().
  
  palindrome(W) -> palindrome(map_data(mapping(W)),"","","").
  palindrome([{W,{N,symmetry}}|T], L, C, R) ->
      NC = if (N rem 2 == 1) and ((C == "") or (W < C)) -> W; true -> C end,
      P = copies(W, N div 2),
      palindrome(T, concat(L, P), NC, concat(P, R));
  palindrome([{W,{N,WR}}|T], L, C, R) ->
      P = copies(W, N div 2),
      PR = copies(WR, N div 2),
      palindrome(T, concat(L, P), C, concat(PR, R));
  palindrome([], L, C, R) -> concat(L, concat(C, R)).
      
  
  mapping(W) -> mapping(W, map_new()).
  