IIRC, Eclipse defaults to Java 1.4 compatibility. In other words, even if you have Java 5 on your machine, by default it will compile your code as if it were for 1.4. This is why printf is not working for you.
Here is a page a quick google search pulled up. Assuming Java 5 is the only version of Java installed on your machine, then this step is the only important one:
Quote:
|
- Set the Eclipse>Preferences>Java>Compiler level to 5.0
|
If you set that option, your code should compile.