In programming languages such as C, you can create an anonymous block of code to limit the scope of variables within a block, can you do the same with Lua?
If so, what will be the Lua equivalent of the following C code?
void function() { { int i = 0; i = i + 1; } { int i = 10; i = i + 1; } }
source share