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.
Ordering elements in collection
Is it a palindrome list?
Report a typo
Sample Input 1:
anne peter anneSample Output 1:
trueWrite a program in Kotlin
/* Do not change code below */
fun main() {
val list = readln().split(" ")
// write your code here
val res =
println(res)
}
___
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.