Even though I manually configured JDK project structure file/Project structure it still shows this error FAILURE: Build failed with an exception.
`What went wrong: Execution failed for task ':sample:compileReleaseJavaWithJavac'.
Could not find tools.jar. Please check that C:\Program Files\Java\jre1.8.0_151 contains a valid JDK installation.`
I'm confused why it is still looking for C:\Program Files\Java\jre1.8.0_151 instead of JDK
JAVA_HOME
environment variable? And is the JRE higher in yourPATH
? Why even install a JRE (the JDK includes one)? – Elliott Frischc:/windows/program Files/
? Are you sure? – Elliott Frisch