Problem: You have compiled a class from a source file in a package. For example:
The class compiles fine. But when you go to run it you get an error.
Exception in thread "main" java.lang.NoClassDefFoundError: Myclass(wrong name: mypackage/MyClass)
Solution: You can not use a backslash in a Java class path. Instead you need to use a forward slash.
Better yet, as a best practice, always use a dot to specify the class name. This avoids the slash issue altogether.
That should solve any future runtime errors for classes in a package.