Is it a palindrome list?

Report a typo

We have a list of words. Is this list itself a palindrome? Remember: a palindrome is a sequence of items which reads the same backward as forward. Based on this definition and using the position of the elements, check if reading this list from start to finish and vice versa produces the same result.

Sample Input 1:

anne peter anne

Sample Output 1:

true
Write a program in Kotlin
/* Do not change code below */
fun main() {
val list = readln().split(" ")
// write your code here
val res =


println(res)
}
___

Create a free account to access the full topic