#include<stdio.h>
int main()
{
char str1[10];
char temp;
char *sptr1;
char *sptr2;
int len;
sptr1=str1;
sptr2=str1;
while(*sptr1!='\0')
{
sptr1++;
}
len=sptr1-str1;
printf("Length of the string:%d\n",len
); sptr1--;
while(len>0)
{
temp=*sptr1;
*sptr1=*sptr2;
*sptr2=temp;
sptr1--;
sptr2++;
len=len-2;
}
}
I2luY2x1ZGU8c3RkaW8uaD4KaW50IG1haW4oKQp7CiBjaGFyIHN0cjFbMTBdOwogY2hhciB0ZW1wOwoKIGNoYXIgKnNwdHIxOwogY2hhciAqc3B0cjI7CiBpbnQgbGVuOwogcHJpbnRmKCJFbnRlciBhIHN0cmluZzpcbiIpOwogc2NhbmYoIiVzIixzdHIxKTsKIHNwdHIxPXN0cjE7CiBzcHRyMj1zdHIxOwogd2hpbGUoKnNwdHIxIT0nXDAnKQogewogIHNwdHIxKys7CiB9CiBsZW49c3B0cjEtc3RyMTsKIHByaW50ZigiTGVuZ3RoIG9mIHRoZSBzdHJpbmc6JWRcbiIsbGVuKTsKIHNwdHIxLS07CiB3aGlsZShsZW4+MCkKIHsKICB0ZW1wPSpzcHRyMTsKICAqc3B0cjE9KnNwdHIyOwogICpzcHRyMj10ZW1wOwoKICBzcHRyMS0tOwogIHNwdHIyKys7CiAgbGVuPWxlbi0yOwogfQogIHByaW50ZigiJXNcbiIsc3RyMSk7CiB9