Implement a method that accepts a queue and returns its last element.
Concurrent queues
Last element
Report a typo
Write a program in Kotlin
import java.util.Queue
fun getLastNumber(target: Queue<Int>): Int {
// implement
}
___
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.