2 ms·
I like the way Lua handles strings and numbers quite a bit. They're different types, but arithmetic will convert a string to a number when it can. This is with
by samatman 3y ago
I like the way Lua handles strings and numbers quite a bit. They're different types, but arithmetic will convert a string to a number when it can.
This is without footguns, because concatenation is a different operator entirely.
2 + "3" -- 5
2 .. "3" -- "23"
It's rather convenient, especially when you can combine it with LPeg to parse files with numbers in them, then do the maths directly.