List of names

Report a typo

You have a list of first names of your students. Please return a list with the names following the LIFO strategy.

Sample Input 1:

john jane joe jill pack

Sample Output 1:

pack jill joe jane john
Write a program in Kotlin
fun processNamesLIFO(names: ArrayDeque<String>): ArrayDeque<String> {
val outputStack = ArrayDeque<String>()

// make your code here

return outputStack
}
___

Create a free account to access the full topic