object Test {
  def main(args: Array[String]): Unit = {
    assert(List.iterate(List(1,2,3), 4)(_.tail).last.isEmpty)
    assert(LazyList.iterate(LazyList(1,2,3), 4)(_.tail).last.isEmpty)
    assert(Array.iterate(Array(1,2,3), 4)(_.tail).last.isEmpty)
  }
}
