1. You are given a linked list letters in the English alphabet (a to z)
in lowercase.
2. You have to write a function that arranges the consonants and vowel
nodes of the list in such a way that all the vowel nodes come before
the consonants while maintaining the order of their arrival.
3. Node class represents the node of Linked List.
4. display is a utility function which displays the contents of Linked List,
feel free to use it for debugging purposes.
5. main takes input from the users and creates the Linked List. You can use
display to know its contents.
6. This is a functional problem.
6. You should code only the arcv function, feel free to change its
signature if required. It should return the head of the linked list.
7. Don't change the code of Node, main and display.Input Format
First line takes N, the number of elements in the list. Next line takes input N space separated characters, a-z in lowercase. Input is handled for you.
Output Format
N space separated characters, vowels and consonants separated. Output is handled for you.
Constraints
1 <= N <= 100
Notice
Try First, Check Solution later
1. 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.Example
Input
6 a e g h i m
Output
a e i g h m