There's some examples of running programs here:
http://faq.cprogramming.com/cgi-bin/smartfaq.cgi?answer=1044654269&id=1043284392

What compiler are you using?