Kod:
public class Main {
public static void main(String[] args){
int age = 23;
System.out.println(10*age);
}
}
Kodunu yazdım ve çalıştırdım ama aşağıdaki hatayı alıyorum.
Kod:
22:28:32: Executing ':app:Main.main()'...
FAILURE: Build failed with an exception.
* Where:
Initialization script 'C:\Users\Kullanici\AppData\Local\Temp\Main_main__.gradle' line: 41.
* What went wrong:
A problem occurred configuring project ':app'.
> Could not create task ':app:Main.main()'.
> SourceSet with name 'main' not found.
* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 302ms.
Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.
You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
See https://docs.gradle.org/7.4/userguide/command_line_interface.html#sec:command_line_warnings
22:28:32: Execution finished ':app:Main.main()'.