local my_string = "[I wish you a happy birthday]"local new_string = string.gsub(my_string:gsub('^%[', ''), ']$', '')print(new_string)
Standard input is empty
I wish you a happy birthday
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!