Is there a difference if I compile the following program using c89 vs c99? I get the same output. Is there really a difference between the two?
#include <
In theory, there should be one difference. Using "//" to demark a comment isn't part of C89, so if it enforced the C89 rules correctly, that would produce a compiler error (with -ansi -pedantic, it might do that, but I don't remember for sure).
That gives an idea of the general character though: if a program compiles as C89, it'll generally also compile as C99, and give exactly the same results. C99 mostly buys you some new features that aren't present in C89, so you can use (for example) variable length arrays, which aren't allowed in C89.
You may have to ask for pedantic rules enforcement to see all the differences though -- C99 is intended to standardize existing practice, and some of the existing practice is gcc extensions, some of which are enabled by default.