Created
January 10, 2015 22:49
-
-
Save nefftd/a7f1bdc3e7d591c5002f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| C:\Users\Neffi | |
| λ lua | |
| Lua 5.2.3 Copyright (C) 1994-2013 Lua.org, PUC-Rio | |
| > local t={}; for i = 1,950000 do t[i]='a' end; local tprime = table.pack(table.unpack(t,1,#t/2)); print(#tprime) | |
| 475000 | |
| > local t={}; for i = 1,1000000 do t[i]='a' end; local tprime = table.pack(table.unpack(t,1,#t/2)); print(#tprime) | |
| 500000 | |
| > local t={}; for i = 1,1200000 do t[i]='a' end; local tprime = table.pack(table.unpack(t,1,#t/2)); print(#tprime) | |
| 600000 | |
| > local t={}; for i = 1,2200000 do t[i]='a' end; local tprime = table.pack(table.unpack(t,1,#t/2)); print(#tprime) | |
| stdin:1: too many results to unpack | |
| stack traceback: | |
| [C]: in function 'unpack' | |
| stdin:1: in main chunk | |
| [C]: in ? | |
| > |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment