I have a tricky requirement:
I need to use bash to compile 100 programs, say 1.c, 2.c, 3.c ... 100.c, I want to keep those c programs which was compiled successfully and remove c programs which compilation errors.
Up to now I can only achieve the goal that compiling those 100 programs but I really have no idea how to detect whether there was failed compilation in these 100 programs.
 
    