0

I have an project in GitHub and have some class.

I want to run a simple code.

public class team_32 {
public static void main(String[] args) {
    System.out.println("hi");
}

But i face to this error.

I search in post of this error and do some guidance but this error is still.

this is some post I check :

Error "ClassNotFoundException" in IntelliJ IDEA

Intellij suddenly throwing ClassNotFoundException

please help me.

Exception:

at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:123)
Community
  • 1
  • 1
Ali
  • 145
  • 1
  • 2
  • 7

1 Answers1

0

It seems like your configuration is somehow broken. I couldn't reproduce this on my machine, but I have an idea how you can move forwards.

The simplest thing to do to get this snippet of code working is to create a new project (File -> New -> Project). Select Java then next and check the Create project from template checkbox. Highlight Command Line App and hit next, enter a title and click finish.

You should then have a project with working defaults and should be able to paste your main method body into the provided one to get it running.

Sam
  • 670
  • 1
  • 6
  • 20