SHARE
TWEET

Untitled

a guest Nov 18th, 2018 117 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local Split L1 L2 in
  2.    proc {Split L L1 L2}
  3.       case L of nil then
  4.      L1 = nil
  5.      L2 = nil
  6.       [] H|T then
  7.      local A B in
  8.         L2 = A
  9.         L1 = H|B
  10.         {Split T A B}
  11.      end
  12.      
  13.       end
  14.    end
  15.    
  16.    {Split [1 2 3 4 5] L1 L2}
  17.    {Browse L1}
  18.    {Browse L2}
  19. end
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top