Comparing two integers and displaying the greater one

Report a typo

You are given a program that compares two integers `numberA` and `numberB`. Your task is to fill the blanks in the code to print out whichever number is greater. Use an 'if' expression to compare the two numbers and string templates to display the result. Make sure your solution uses relational operators for comparison.

Fill in the gaps with the relevant elements
fun main() {
    val numberA = 10
    val numberB = 20
    val result = (numberA > numberB) "Number A ($numberA) is greater than Number B ($numberB)" 
                  "Number B ($numberB) is greater than Number A ($numberA)"
    (result)
}
ifelseprintln
___

Create a free account to access the full topic