Error: Could not find or load main class SHAHashingExample
Example 1: > Task :run FAILED Error: Could not find or load main class Caused by: java.lang.ClassNotFoundException:
Check your build.gradle file and update the application block:
application {
mainClassName = 'packageName.MainClass'
}
Example 2: Error: Could not find or load main class Hello Caused by: java.lang.ClassNotFoundException: Hello studio visual code
package dto;
public class HelloHP {
public static void main(String args[]) {
System.out.println("My first program in Java, HelloWorld !!");
}
}