I have two java classes as follows
App1 without a package:
class App1 {
public static void main(String[] args) {
System.out.
You have to put -d directory Options..because
Set the destination directory for class files. If a class is part of a package, javac puts the class file in a subdirectory reflecting the package name, creating directories as needed. For example, if you specify -d c:\myclasses and the class is called com.mypackage.MyClass, then the class file is called c:\myclasses\com\mypackage\MyClass.class.