for temp strlen i-1 strlen i-1 temp

1
2
3
4
5
6
for(i = 0; i < n; i++)
{
temp = s[i];
s[i] = s[strlen(s) - i-1];
s[strlen(s) - i-1] = temp;
}