HI i have 3 java files
a.java b.java c.java
I managed to generate .class files for both a and b using
javac example/a
Presumably you're not in the example/ directory when you run javac. Try
example/
javac
javac -cp example c.java
Or just cd into that directory. The classpath is not automatically resolved for the classes c.java depends on.
cd
c.java