It should be work for Dynamic input
For Example Input: Hello Good to See You Output: HellG ooot dS oeY eou
char *p="India"; char t[10]="USA";
after the swap t should contain India and p as USA.
Why is processing a sorted array faster than an unsorted array? Please explain with an example along with its advantages.