Ds\Sequence::first

(PECL ds >= 1.0.0)

Ds\Sequence::firstReturns the first value in the sequence

˵��

abstract public Ds\Sequence::first ( void ) : mixed

Returns the first value in the sequence.

����

�˺���û�в�����

����ֵ

The first value in the sequence.

�����쳣

UnderflowException if empty.

����

Example #1 Ds\Sequence::first() example

<?php
$sequence 
= new \Ds\Vector([123]);
var_dump($sequence->first());
?>

�������̵���������ڣ�

int(1)