#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
void reverse_string(char arr[], int sz)
{
int left = 0;
int right = sz - 1;
while (arr[left] < arr[right])
{
int tmp = arr[left];
arr[left] = arr[right];
arr[right] = tmp;
left++;
right--;
}
}
int main()
{
char arr[] = "abcdefg";
int n = 0;
int sz = 0;
while (arr[n] != '\0')
{
sz++;
n++;
}
reverse_string(arr, sz);
printf("%s",arr);
return 0;
}