Segregate Even And Odd Nodes In A Linkedlist
Try First, Check Solution later1. You should first read the question and watch the question video.2. Think of a solution approach, then try and submit the question on editor tab.3. We strongly advise you to watch the solution video for prescribed approach.
Given a singly linklist, modify the list such that all the even numbers appear before all the odd numbers in the modified list. The order of appearance of numbers within each segregation should be same as that in the original list.Input Format
0 <= N <= 10^6Sample Input
0 6 7 5
Asked in Companies