# include & lt; stdio.h>
# include
Int main (void)
{
Int I, j, n.
Char name [26].//define an array
Printf (" Pls enter your name: \ n ");
Scanf_s (" % s ", name);//the input words in array
N=strlen (name);//use strlen digit of the input word is assigned to the n
For (I=0, j=n; I & lt; n; I++)
Printf (" % c ", the name [- j]);
system("pause");
return 0;
}
CodePudding user response:
scanf_s (" % s ", name, 26).//the input words stored in an array of
For your reference ~
Scanf_s for % s need to the length of the input buffer, on the one hand, it is safer than the scanf scanf_s
CodePudding user response:
Learning, not the same