Fortune Telling Collection - Fortune-telling birth date - C language inversion name (string)

C language inversion name (string)

# Contains? & ltiostream & gt

Use? Namespace? std

Invalid? reverseFixlen(char? *str,? int? n)

{

int? Me? =? 0;

And (me? & lt? n/2)

{

Charles? c? =? str[I];

str[i]? =? str[n-I- 1];

str[n-i- 1]? =? c;

i++;

}

}

Invalid? reversewordsinsentent(char? *sen)?

{

int? Ryan. =? Stern (Sen);

ReverseFixlen (Sen, Len);

Charles? *p? =? Sen;

while(*p? ! =? '\0')

{

Charles? *pre? =? p;

while((*p? ! =? '?' )& amp& amp(*p? ! =? '\0'))

p++;

reverseFixlen(pre,p-pre);

If (*p? ==? '\0')

Break;

p++;

}

}

The test code is as follows:

Charles? sen[]? =? "Gary? Bronson ";

reversewordsinsentent(sen);

int? j? =? 0;

while(sen[j]? ! =? '\0')

cout? & lt& lt? sen[j++];