print (string.match("See this example (figure 1)", "%((figure%s*%d+)%)"))
Standard input is empty
figure 1
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!