1. Both are fine. Maven is declarative XML with one standard way of doing things, so there is less to decide. Gradle is more flexible and usually faster on incremental builds, but that flexibility is also more to learn. If your course or book uses one, take that one. Otherwise I would start with Maven.
2. Not required, Groovy DSL still works, but Kotlin DSL is the default for new projects from gradle init and gives better IDE completion.
Whatever you choose, use the wrapper (mvnw / gradlew) so the build tool version is fixed in the repository.
A minimal Maven pom.xml for JDK 25:
<project xmlns="http://maven.apache.org/POM/4.0.0">
<modelVersion>4.0.0</modelVersion>
<groupId>ge.example</groupId>
<artifactId>hello</artifactId>
<version>1.0.0</version>
<properties>
<maven.compiler.release>25</maven.compiler.release>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
</project>
The same in Gradle, build.gradle.kts:
plugins {
application
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(25)
}
}
application {
mainClass = "ge.example.App"
}