Coming back to this, is there any plausible reason...
# getting-started
n
Coming back to this, is there any plausible reason why from the tenth char onwards values stop being multiplied by 2?
Copy code
fun getWordValue() {
        val lettersToValues = repository.arr.associate { it.name to it.value }
        word.value!!.forEachIndexed { i, c: Char ->
                if (i in 0..2) {
                    lettersToValues.getValue(c.toString())
                } else {
                   lettersToValues.getValue(c.toString()) * 2
                }
                wordValue.value = c.toString().sumOf { i }
            } 
    }