Well, why cant you run, I mean, what happens when you run it? nothing is displayed? you may need to include a getch() before the last closing braces in the main function, to view the output. If you dont, then press alt+f5 to view the output after you run the program.
PS: include conio.h if you use getch()