Concatenation
Concatenation is a binary operation in which two strings are joined together, creating one larger string, one following the other. In Lua, the concatenation operator is written ..
.
Properties
Concatenation is associative, meaning that , where is the concatenation operator. However, it is not commutative, meaning that .
Example
print("hello" .. " world" .. "!")
This will output hello world!
.
gollark: Yes, but these are cooler.
gollark: Use one of these: https://ubq323.website/competition/3/
gollark: Imagine using classes for any purpose.
gollark: I thought everyone used monoids.
gollark: True, true.
This article is issued from Computercraft. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.