# Algorithms_in_C++: operations_on_datastructures/circular_linked_list.cpp File Reference

Loading...
Searching...
No Matches
circular_linked_list.cpp File Reference

Implementation for a Circular Linked List. More...

`#include <cassert>`
`#include <iostream>`
`#include <vector>`
Include dependency graph for circular_linked_list.cpp:

## Classes

struct | operations_on_datastructures::circular_linked_list::Node
| A Node struct that represents a single Node in a Binary Tree. More...
class | operations_on_datastructures::circular_linked_list::CircularLinkedList
| A class that implements a Circular Linked List. More...

## Namespaces

namespace | operations_on_datastructures
| for std::vector
namespace | circular_linked_list
| Functions for the Circular Linked List implementation.
namespace | tests
| Testcases to check Union of Two Arrays.

## Functions

void | tests::test1 ()
| A Test to check an simple case. More...
void | tests::test2 ()
| A Test to check an empty vector. More...
void | tests::test3 ()
| A Test to check an invalid shift value. More...
void | tests::test4 ()
| A Test to check a very large input. More...
void | tests::test5 ()
| A Test to check a shift of zero. More...
static void | test ()
| Function to test the correctness of the Circular Linked List. More...
int | main ()
| main function More...

## Detailed Description

Implementation for a Circular Linked List.

A Circular Linked List is a variation on the regular linked list, in which the last node has a pointer to the first node, which creates a full circle. Consequently, this allows any node to be used as the starting point for the list.

Author
  Alvin

## Function Documentation

## main()

int main | ( | void |  | ) |

main function

Returns
  0 on exit

{
test(); // run self-test implementations
return 0;
}
test
static void test()
Function to test the correctness of the Circular Linked List.
Definition: circular_linked_list.cpp:333
Here is the call graph for this function:

## test()

static void test | ( |  | ) |

static

Function to test the correctness of the Circular Linked List.

Returns
  void

{
tests::test1();
tests::test2();
tests::test3();
tests::test4();
tests::test5();
}
tests::test1
void test1()
A Test to check an simple case.
Definition: array_left_rotation.cpp:75
tests::test4
void test4()
A Test to check a very large input.
Definition: array_left_rotation.cpp:120
tests::test3
void test3()
A Test to check an invalid shift value.
Definition: array_left_rotation.cpp:105
tests::test2
void test2()
A Test to check an empty vector.
Definition: array_left_rotation.cpp:90
tests::test5
void test5()
A Test to check a shift of zero.
Definition: array_left_rotation.cpp:143
Here is the call graph for this function: