C++ ile yaziyi tersten yazma
#include <iostream.h>
void request(void);
void response(void);
void try_again(void);
int main() {
cout << "Created By MTDesign -
[email protected]" << endl
<< "THE OPPOSITE OF THE WORD" << endl
<< endl;
request();
response();
try_again();
}
void request(void) {
char text[100];
cout << "------------------------" << endl;
cout << "Please Enter a Word : ";
cin >> text;
}
void response(void) {
char text[100];
int i;
cout << "Opposite : ";
for (i=strlen(text); i>=0; i--) {
cout << text[i];
}
cout << "\n------------------------" << endl;
}
void try_again(void) {
char quest;
cout << "\nTry Again ... ? E/H : ";
cin >> quest;
if (quest=='E' || quest=='e')
main();
}