Can Kotlin script use in Android

I want to run kotlin script in string form in Android, like the following:

    val engine = KotlinJsr223DefaultScriptEngineFactory().getScriptEngine()
    engine.eval("val x =3")
    val result = engine.eval("x+2")
    Log.d("ttaylor", "onCreate: result=$result")

but there is an error “Cannot access ‘javax.script.ScriptEngineFactory’ which is a supertype of ‘kotlin.script.experimental.jsr223.KotlinJsr223DefaultScriptEngineFactory’. Check your module classpath for missing or conflicting dependencies”

the dependency i add is:

implementation "org.jetbrains.kotlin:kotlin-scripting-jsr223:1.4.0"
implementation "org.jetbrains.kotlin:kotlin-script-runtime:1.4.0"
implementation "org.jetbrains.kotlin:kotlin-compiler-embeddable:1.4.0"

Is my goal achievalbe? or am i doing it in the right way?