Question DSA-LL-0058
MediumHow do you find the length of a loop in a linked list after Floyd's pointers meet?
- A.
It can't be found
- B.
Count all nodes from the head
- C.
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Linked Lists question
How do you find the length of a loop in a linked list after Floyd's pointers meet?
It can't be found
Count all nodes from the head
Sign up free to see the answer and a step-by-step explanation.
Reverse the list
Keep one pointer still and move the other around until they meet again, counting steps