how to run package java program in cmd code example Example: compile java code with package in cmd javac –d . demo.java