downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | conferences | my php.net

search for in the

SplDoublyLinkedList::__construct> <SplDoublyLinkedList
[edit] Last updated: Fri, 17 May 2013

view this page in

SplDoublyLinkedList::bottom

(PHP 5 >= 5.3.0)

SplDoublyLinkedList::bottomPeeks at the node from the beginning of the doubly linked list

Descrição

mixed SplDoublyLinkedList::bottom ( void )

Parâmetros

Esta função não possui parâmetros.

Valor Retornado

The value of the first node.

Erros

Throws RuntimeException when the data-structure is empty.



add a note add a note User Contributed Notes SplDoublyLinkedList::bottom - [1 notes]
up
1
rakesh dot mishra at gmail dot com
2 years ago
<?php

/*
 * Examples of DoublyLinkedList
 */

$obj = new SplDoublyLinkedList();

// Check wither linked list is empty
if ($obj->isEmpty())
{
    echo
"Adding nodes to Linked List<br>";
   
$obj->push(2);
   
$obj->push(3);
   
    echo
"Adding the node at beginning of doubly linked list <br>";
   
$obj->unshift(10);
}

echo
"<br>Our Linked List:";
print_r($obj);

echo
"<br>Pick the node from beginning of doubly linked list";
echo
$obj->bottom();

?>

 
show source | credits | stats | sitemap | contact | advertising | mirror sites