So am literally taking a intro to Java Programming and now I am trying to create my second assignment. Upon doing so I have created the new java class within eclipse, but when I try to run the code that I have written, I am getting the following errors.
I am not real sure on how to fix this. Any assistance would be greatly appreciated.
Exception in thread "main" java.lang.NoClassDefFoundError: math
Caused by: java.lang.ClassNotFoundException: math
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
ClassNotFoundException: math
I’m guessing you created a class with a capital M in math, but when you call it somewhere, it’s not capitalized, or referenced properly. Try to double check that in your code.
Friendly FYI for proper Java standards, try to make sure that classes are capitalized.