hi..i am having problem in writing a function which returns a boolean value if the linked list is circular or not...the linked list is singly...moreover the circular means here not simply last node next is first node but linked list can be circular from any node to any node...
i am giving below the basic syntax that i have implemeted but i am not getting how can i implement using two pointers...the parameter to the function is the head of the linked list and remember you dont have to use here the value of the node...
bool samplefunction(linkedlist header)
{
linkedlist p1,p2;
return bool;
}
thanks in advance...