#include <stdio.h>
#include <string.h>
void reverse_string(char* str) {
int end_i = strlen(str) - 1;
for (int start_i = 0; start_i < end_i; start_i++, end_i--) {
int temp = str[end_i];
str[end_i] = str[start_i];
str[start_i] = temp;
}
}
int main(int argc, char* argv[]) {
if (argc < 2) {
printf("%s {string}\n", argv[0]);
return 0;
}
printf("%s\n", argv[1]);
reverse_string(argv[1]);
printf("%s\n", argv[1]);
return 0;
}