Hey it is very easy program to reverse the order of the letters using linked list. I have written following code for you. In the following code I have use iostream class to include all input and output method. I also have use one array variable to accept all string.
Code:
#include <iostream>
using namespace std;
int main(){
char as[9] = {'a','b','c','d','e','f','g','h','i'};
for (int k=1;k<=9;k++){
as[k-1];
}
cout<<"the output in reverse order \n";
for (int k=8;k>=0;k--)
cout<<as[k]<<endl;
char cs;
cin>>cs;
}
Bookmarks