Brief Overview on Linked List
This documentation is written in a way to introduce the idea of a linked list
 
Loading...
Searching...
No Matches
linked_list.hpp File Reference

C++ Header file that declares all of the methods and properites of a linked list. More...

#include "node.hpp"
#include <vector>
#include <ostream>

Go to the source code of this file.

Classes

class  Linked_list
 Linked List Class with Methods and Properties. More...
 

Functions

std::ostream & operator<< (std::ostream &out, Linked_list const &lst)
 Operator Overloading to be able to format the memebers of a linked list in a personalized view.
 

Detailed Description

C++ Header file that declares all of the methods and properites of a linked list.

Function Documentation

◆ operator<<()

std::ostream & operator<< ( std::ostream & out,
Linked_list const & lst )

Operator Overloading to be able to format the memebers of a linked list in a personalized view.

Allows this function to access the private member variables.

Parameters
outThe output data
lstThe Linked list object

Example

Linked_list lst = Linked_list( std::vector<int>( 4, 5 ) );
std::cout << lst << std::endl;
Linked List Class with Methods and Properties.
Definition linked_list.hpp:15

Output:

HEAD -> 5 -> 5 -> 5 -> 5 -> NULLPTR