这个递归是如何实现的啊 帮忙给解释一下
#include <stdio.h>void reverse(const char * const sPtr);
int main()
{
char sentence [ 80 ];
printf("Enter a line of text:\n");
fgets( sentence, 80, stdin);
printf("\nThe line print backword is :\n");
reverse( sentence);
printf("\n");
return 0;
}
void reverse( const char * const sPtr)
{
if( sPtr[ 0 ] == '\0'){
return;
}
else{
reverse( &sPtr[ 1 ]);
putchar( sPtr[ 0 ]);
}
}
帮忙给解释一下reverse( &sPtr[ 1 ]);
putchar( sPtr[ 0 ]);