/**
* brief 将输入的字符串转成倒序
*
* param [in,out] str 输入输出字符串
*
* author hjwang
* date 2010-08-27
*
*/
void _strRevert(CHAR * str)
{
INT32 length = strlen(str);
CHAR temp;
INT32 i;
for(i = 0; i < length/2; i++)
{
temp = *(str + i);
*(str + i) = *(str + length - 1 - i);
*(str + length - 1 - i) = temp;
}
}[@more@]
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/7282477/viewspace-1038459/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/7282477/viewspace-1038459/