I am getting an error "Gradle failed to fetch dependencies" for Google admob plugin

I am getting this error when integrating Google Admob Plugin when try to force resolve from Android Resolver.

Gradle failed to fetch dependencies.

Failed to run ‘C:\Users\mouhammad\Desktop\My games!\CashCapitalist\Temp\PlayServicesResolverGradle\gradlew.bat -b “C:\Users\mouhammad\Desktop\My games!\CashCapitalist\Temp\PlayServicesResolverGradle\PlayServicesResolver.scripts.download_artifacts.gradle” --no-daemon “-PANDROID_HOME=C:/Users/mouhammad/AppData/Local/Android/Sdk” “-PTARGET_DIR=C:\Users\mouhammad\Desktop\My games!\CashCapitalist\Assets\Plugins\Android” “-PMAVEN_REPOS=https://maven.google.com/” “-PPACKAGES_TO_COPY=com.google.android.gms:play-services-ads:15.0.1”’
stdout:

stderr:
Exception in thread “main” java.lang.RuntimeException: Could not determine wrapper version.
at org.gradle.wrapper.GradleWrapperMain.wrapperVersion(GradleWrapperMain.java:111)
at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:61)
Caused by: java.lang.RuntimeException: No build receipt resource found.
at org.gradle.wrapper.GradleWrapperMain.wrapperVersion(GradleWrapperMain.java:97)
… 1 more

exit code: 1

UnityEngine.Debug:LogError(Object)
Google.Logger:Log(String, LogLevel)
GooglePlayServices.PlayServicesResolver:Log(String, LogLevel)
GooglePlayServices.c__AnonStorey17:<>m__27(Result)
GooglePlayServices.c__AnonStorey19:<>m__32()
Google.RunOnMainThread:ExecuteNext()
Google.RunOnMainThread:m__6()
Google.RunOnMainThread:RunAction(Action)
Google.RunOnMainThread:ExecuteAll()
Google.RunOnMainThread:Run(Action, Boolean)
GooglePlayServices.c__AnonStorey17:<>m__28(Result)
GooglePlayServices.c__AnonStorey17:<>m__29(Result)
GooglePlayServices.ProgressReporter:SignalComplete()
GooglePlayServices.ProgressReporter:CommandLineToolCompletion(Result)
GooglePlayServices.c__AnonStorey2:<>m__3()
Google.RunOnMainThread:ExecuteNext()
Google.RunOnMainThread:m__6()
Google.RunOnMainThread:RunAction(Action)
Google.RunOnMainThread:ExecuteAll()
UnityEditor.EditorApplication:Internal_CallUpdateFunctions()

Most likely issue is the Exclamation mark(!) in your path (My Games!). That apparently messes up many java based things.

Delete all Google AdS files from the Asset Name folder and re-import the Google AdS package.

Or

-Right click on “my computer” and go to properties.

-Go to the Advanced tab

-Click on the Environmental Variables button

-Find the JAVA_HOME variable under System Variables

-Change the value to wherever this file actually exists for you. (for me it was C:\Program Files\Java\jdk-10)

-Restart Unity