Time:02-20
CodePudding user response:
scanf_s (" % s ", name, 39);
scanf_s other usage, and the scanf is consistent, however, Each % % s or c format character need corresponding to the two parameters, the second is the length limit,
# include # define PARISE. "" you are a extraordinary being." Int main () {Char name [40]. Printf (" what is your name?" ); Scanf_s (" % s ", name, 40). Printf (" Hello, % s. % s \ n ", the name, PARISE); return 0; }
for reference: # include # define PARISE. "" you are a extraordinary being." Int main () {Char name [40]. Printf (" what is your name?" ); Scanf_s (" % s ", name, 40). Printf (" Hello, % s. % s \ n ", the name, PARISE); return 0; } Refer to baidu: https://www.zhihu.com/question/64044016
Quote: refer to the sixth floor QZJHJXJ response: for reference: # include # define PARISE. "" you are a extraordinary being." Int main () {Char name [40]. Printf (" what is your name?" ); Scanf_s (" % s ", name, 40). Printf (" Hello, % s. % s \ n ", the name, PARISE); return 0; } Refer to baidu: https://www.zhihu.com/question/64044016 No, an error that is not a statement of identifier,
Quote: refer to the eighth floor qq_52473673 response: Quote: refer to the sixth floor QZJHJXJ response: for reference: # include # define PARISE. "" you are a extraordinary being." Int main () {Char name [40]. Printf (" what is your name?" ); Scanf_s (" % s ", name, 40). Printf (" Hello, % s. % s \ n ", the name, PARISE); return 0; } Refer to baidu: https://www.zhihu.com/question/64044016 No, an error that is not a statement of identifier, Sorry, just now I made a mistake, already can, thank you.
Quote: refer to 1st floor forever74 response: scanf_s (" % s ", name, 39); Why do want to take a 39 behind ah,
the scanf () is not to use & amp; Symbols to draw address to receive? Scanf_s should also need,,,
Page link:https//www.codepudding.com/Backend/101967.html