Variable is never used

I am new to learning Kotlin while reading the docs I was learning variables and I went to test it in the Kotlin playground while testing I came across this error I have searched everywhere and have not found a way to fix it the error is.

Variable (BLANK) is never used.

my code is

fun main() {
     val ACTION_MOVE: Int
}

That’s just a warning, not an error. You can simply ignore it. However, I think you need to specify an initial value for your ACTION_MOVE variable, like so:

val ACTION_MOVE: Int = 0
1 Like

Thanks out so much your the best :slight_smile:

2 Likes