in reply to Matching lines in a file that end in numbers (was: regular expression)

If you want to compile the output then surely you're going to need all of the lines, not just the ones tbat started off ending with numbers.

If that's the case I think what you want is:
find . -name "*.c" -exec perl -ne 's/\d+$//; print' {} \;
which strips any numbers from the end of the lines and prints them all.