Integer Value Help

Does anyone know how to add numbers to an integer value while not physically adding them together . For example, if I want to add 12 and 10 to the value I would want “1210” not “22”.

I was doing:

Int.Value = Int.Value + “12”

Thank you.

function AddNumbersTechnically(num1,num2)
	return string.format(num1.."%i",num2)
end

print(AddNumbersTechnically(10,23))

You can concatenate two integers by converting them to a string first, concatenating them, then converting them back into an integer.

function concatenateNumbers(n1, n2)
     return tonumber(tostring(n1)..tostring(n2))
end
print(concatenateNumbers(50,32))

Yes, I’m late. But maybe it will help someone.

First = "10" -- you can choice random
Second = "22" -- you can choice random

E = tostring(First..Second) -- In fact, we take and simply attach the first to the second

print(E)

You do not need to tostring() the numbers.

local a = 5
local b = 2

local c = a .. b

print(c) -- 52