i want to remove separation characters from inbetween numbers in lua. For example: 19,300 -> 19300.
I am able to extract the two "parts" of the number using
a,b = string.match(amount, '(%d+),*(%d*)')
but have to store the results in two separate variables first. I would like to have a clean way of storing all capture groups as a concatinated, single variable, instead of having to do c=a..b in an extra step. Is there a way to achieve this?
a = amount:gsub(',','')- Mike V.c = amount:gsub("%f[%D],%f[%d]", ""):match"%d+"- Egor Skriptunoff